Tag: scope

60 votes
9 answers
825 views
Is it possible to define more than one function per file in MATLAB, and access them from outside that file?

When I was studying for my undergraduate degree in EE, MATLAB required each function to be defined in its own

avatar
Majorie
0 1 0 9
asked 07 September, 2021
60 votes
19 answers
2.5K views
What's the correct way to communicate between controllers in AngularJS?

What's the correct way to communicate between controllers? I'm currently using a horrible fudge inv

avatar
Lashawna
0 1 0 9
asked 07 September, 2021
55 votes
28 answers
2.2K views
AngularJS : Prevent error $digest already in progress when calling $scope.$apply()

I'm finding that I need to update my page to my scope manually more and more since building an applicatio

avatar
Kurtis
0 1 0 9
asked 07 September, 2021
56 votes
7 answers
1.9K views
'this' vs $scope in AngularJS controllers

In the "Create Components" section of AngularJS's homepage, there is this example: controller: function(

avatar
Suzan
0 1 0 9
asked 07 September, 2021
53 votes
18 answers
3.1K views
What is the difference between '@' and '=' in directive scope in AngularJS?

I've read the AngularJS documentation on the topic carefully, and then fiddled around with a directive. H

avatar
Luis
0 1 0 9
asked 07 September, 2021
52 votes
6 answers
2.9K views
How do I use $scope.$watch and $scope.$apply in AngularJS?

I don't understand how to use $scope.$watch and $scope.$apply. The official documentation isn't help

avatar
Omar
0 1 0 9
asked 07 September, 2021
58 votes
19 answers
2.2K views
How do I access the $scope variable in browser's console using AngularJS?

I would like to access my $scope variable in Chrome's JavaScript console. How do I do that? I can neithe

avatar
Joseph
0 1 0 9
asked 07 September, 2021
65 votes
21 answers
455 views
Using global variables in a function

How can I create or use a global variable in a function? If I create a global variable in one function, how c

avatar
Leonardo
0 1 0 9
asked 07 September, 2021
57 votes
30 answers
1K views
What's the difference between using "let" and "var"?

ECMAScript 6 introduced the let statement. I've heard that it's described as a local variable, but I

avatar
Basil
0 1 0 9
asked 07 September, 2021
62 votes
30 answers
1.9K views
55 votes
23 answers
1.3K views
When should I use 'self' over '$this'?

In PHP 5, what is the difference between using self and $this? When is each appropriate?

avatar
Georgie
0 1 0 9
asked 07 September, 2021