| Age | Commit message (Collapse) | Author |
|
|
|
- both $watch and $on now return a function which when called
deregisters the listener
- $removeListener was removed and replaced with the above
- added more tests for $watch and $on
Closes #542
|
|
- fixed traversal originating on a scope with with a right sibling
- unified code for both $broadcast and $digest
|
|
IE doesn't have Array#indexOf and [].splice.call doesn't work there
either.
|
|
- register listeners with $on
- remove listeners with $removeListener
- fire event that bubbles to root with $emit
- fire event that propagates to all child scopes with $broadcast
|
|
|
|
we commonly assign stuff in if statments like this:
if (variable = someFn()) {
//do something with variable
}
This results in lint and IDE warnings (did you mean ==?).
It is better to be explicit about our intention and wrap the assignement
into parens:
if ((variable = someFn())) {
//do something with variable
}
Doing so suppresses warnings + is easier to understand the intention.
I verified that the closure compiler strips the extra parens, so there
is no byte overhead for this safety practice.
We should use this style going forward...
|
|
|
|
Much faster $destroy operations for large ng:repeat sets.
|
|
|
|
|
|
|
|
|
|
- Speed improvements (about 4x on flush phase)
- Memory improvements (uses no function closures)
- Break $eval into $apply, $dispatch, $flush
- Introduced $watch and $observe
Breaks angular.equals() use === instead of ==
Breaks angular.scope() does not take parent as first argument
Breaks scope.$watch() takes scope as first argument
Breaks scope.$set(), scope.$get are removed
Breaks scope.$config is removed
Breaks $route.onChange callback has not "this" bounded
|
|
Minor documentation fixes. Should not be any code changes.
One test changed due to dependency on text in documentation.
|
|
the flag must be in all src and test files so that we get the benefit of
running in the strict mode even in jstd
the following script was used to modify all files:
for file in `find src test -name "*.js"`; do
echo -e "'use strict';\n" > temp.txt
cat $file >> temp.txt
mv temp.txt $file
done
|
|
8cad231 broke $eager services
Problem is that the injector.eager function is not invoked when a new scope
is created. Added a test to make sure service is eagerly instantiated.
Closes #403
|
|
|
|
|
|
|
|
|
|
|
|
they have no significant effect on minified and gziped size. in fact
they make things worse.
file | before | after removal
----------------------------------------
concat | 325415 | 325297
min | 62070 | 62161
min + gzip | 25187 | 25176
The bottom line is that we are getting 0.05% decrease in size after
gzip without all of the hassle of using underscores everywhere.
|
|
|
|
|
|
|
|
|
|
- fix $log and $exceptionHandler retrieval
- remove reference to non-existent `error` handler
- update tests
|
|
|
|
camelcase is used for other angular functions and forEach is also
used by EcmaScript standard.
- rename the internal as well as the external function name
- tweak the implementation of the function so that it doesn't
clober it self when we extend the angular object with an
object that has a forEach property equal to this forEach function
Closes #85
|
|
see changelog diff for more info
|
|
- RegExp parser is rearly used, feature, and one should not have RegExps
in views anyways, so we are removing it
BACKWARD INCOMPATIBLE CHANGE!!!
|
|
- Delete $postEval method, as it was a hack
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ng-errors
|
|
- if initRun param is set to false, listener doesn't execute
- the oldValue should equal newValue during the initial execution
- added docs
- added specs
|
|
backward incompatible)
|
|
|
|
Close #57
|
|
test rethrow function
|
|
Close #52
|
|
|
|
controllers
- added angular.injector(scope, services, instanceCache) which returns inject
- inject method can return, instance, or call function which have $inject
property
- initialize services with $creation=[eager|eager-publish] this means that
only some of the services are now globally accessible
- upgraded $become on scope to use injector hence respect the $inject property
for injection
- $become should not be run multiple times and will most likely be removed
in future version
- added $new on scope to create a child scope
- $inject is respected on constructor function
- simplified scopes so that they no longer have separate __proto__ for
parent, api, behavior and instance this should speed up execution since
scope will now create one __proto__ chain per scope (not three).
BACKWARD COMPATIBILITY WARNING:
- services now need to have $inject instead of inject property for proper
injection this breaks backward compatibility
- not all services are now published into root scope
(only: $location, $cookie, $window)
- if you have widget/directive which uses services on scope
(such as this.$xhr), you will now have to inject that service in
(as it is not published on the root scope anymore)
|
|
- feedback relies on *Controller.init to be called when a Controller is
being created. this with previous angular refactoring this is not happening
in angular any more. To make it easier for feedback to transition, this
change makes $become call controller's init method if present.
- call to Controller.init from $route.updateRoute was removed. this was
left there by accident during the previous refactoring.
|
|
data bound (ie OPTION has repeater or OPTION.value is bound), then SELECT does not update to match the correct OPTION after the change in model (ie after the OPTION repeater unrolls or OPTION.value is changed.)
|