Permalink
Comparing changes
Open a pull request
35
contributors
Commits on Aug 10, 2016
The quotes rule had to be disabled for e2e tests generated from ngdoc because dgeni templates use double quotes as string delimiters. Since we can't have guarantees that dgeni template wrappers will follow the same JS code style the Angular 1 repo uses, we should find a way to enforce our ESLint setup only for the parts in this repo, perhaps via prepending a generated `/* eslint-enable OUR_RULES */` pragma. (partially cherry-picked from 9360aa2) Closes #15011
Commits on Aug 12, 2016
During the `build` task, the version placeholders will be replaced with the actual values using a RegExp, which expects the placeholders to be surrounded by double quotes. By replacing the quotes from double to single in #15011, the RegExp was not able to match the placeholders. (For reference, the RegExps that match and replace the version placeholders are in [lib/grunt/utils.js][1].) [1]: https://github.com/angular/angular.js/blob/859348c7f61ff5f93b9f81eb7f46842bd018d8e3/lib/grunt/utils.js#L125-L130 Closes #15016
Commits on Aug 17, 2016
Previously, it would throw the ng:areq error, which is less specific and just informs that the requested controller is not defined. Given how commonly controllers are used in Angular, it makes sense to have a specific error. The ng:areq error is still thrown when the registered controller is not a function. Closes #14980 PR (#15015)
This commit fixes the handling of min/max, and removes support for ngMin/ngMax: min/max: Previously, interpolated min/max values on input range were not set when the first $render happens, because the interpolation directive only sets the actual element attribute value after a digest passes. That means that the browser would not adjust the input value according to min/max and the range input and model would not be initialzed as expected. With this change, input range will set the actual element attribute value during its own linking phase, as it is already available on the attrs argument passed to the link fn. ngMin/ngMax Since ng prefixed attributes do not set their corresponding element attribute, the range input would always have min = 0, and max = 100 (in supported browsers), regardless of the value in ngMin/ngMax. This is confusing and not very useful, so it's better to not support these attributes at all. The commit also fixes a test which used an interpolation inside an attribute that expects an expression. Fixes #14982 PR (#14996)
Step support works like min / max, but with the following caveat. Currently, only Firefox fully implements the spec. Other browsers (Chrome, Safari, Edge) have issues when the step value changes after the input has been changed. They do not adjust the input value to a valid value, but instead set the stepMismatch validity state. Angular will take this validity state, and forward it as the ngModel "step" error. Adjusting the error ourselves would add too much code, as the logic is quite involved.
Commits on Aug 18, 2016
Commits on Aug 22, 2016
… attribute In HTML5 mode, links can now be selectively rewritten, by setting `mode.rewriteLinks` to a string (denoting an attribute name). Anchor elements that have the specified attribute will be rewritten, while other links will remain untouched. This can be useful in situations where it is desirable to use HTML5 mode without a `<base>` tag, but still support rewriting specific links only. See #14959 for more details on a possible usecase. Closes #14976
Commits on Aug 26, 2016
…ce, track Previously, video, audio, source, and track sources were $sce.RESOURCE_URL. This is not justified as no attacks (script execution) are possible through these attributes as far as we can tell. Angular2 also uses the same categorization. This change is not breaking, and uses of $sce.trustAsResourceUrl before assigning to src or ng-src attributes will just be silently ignored. This has also been given a LGTM by @mprobst via email. Commit 4853201 on the master branch contains the same changes, but is missing this commit description. This commit does not backport the BC introduced in 04cad41. PR (#15039) Closes #14019
Commits on Aug 30, 2016
This allows the removal of try/catch from addDirective to avoid V8 deopt. Previously the directive.restrict property was not validated. This would potentially cause exceptions on each compilation of the directive requiring a try/catch and potentially causing repeated errors. New validation when directive.restrict is specified: * must be a string * must contain at least one valid character (E, A, C, M) Cases which previously silently failed (now throw an error): * values with an indexOf method (such as strings, arrays) which returned returned -1 for all valid restrict characters Cases which previously worked unintentionally (now throw an error): * arrays with single-character strings of valid restrict characters PR (#13263)
Commits on Sep 01, 2016
Closes #15075
Commits on Sep 07, 2016
A new option to enable/disable whether directive controllers are assigned bindings before calling the controller's constructor. If enabled (true), the compiler assigns the value of each of the bindings to the properties of the controller object before the constructor of this object is called. If disabled (false), the compiler calls the constructor first before assigning bindings. The default value is enabled (true) in Angular 1.5.x but will switch to false in Angular 1.6.x. See #14580 Closes #15095
…alues Closes #15098
Commits on Sep 08, 2016
window.isNaN(‘lol’); //=> true Number.isNaN(‘lol’); //=> false isNaN converts it’s arguments into a Number before checking if it’s NaN. In various places in the code base, we are checking if a variable is a Number and NaN (or not), so this can be simplified with this new method (which is not exported on the global Angular object). Closes #11242
The injection argument is missing the '$' in the two examples. The code fails as written. This change corrects it. (#15099)
…aged Apps While sandboxed Chrome Packaged Apps (CPAs) have the same restrictions wrt accessing `history.pushState` as "normal" CPAs, they can't be detected in the same way, as they do not have access to the same APIs. Previously, due to their differences from normal CPAs, `$sniffer` would fail to detect sandboxed CPAs and incorrectly assume `history.pushState` is available (which resulted in an error being thrown). This commit fixes the detection of sandboxed CPAs in `$sniffer`. See #11932 and #13945 for previous work. Closes #15021
Commits on Sep 10, 2016
- Remove internal `makePromise()` helper. - Remove unnecessary wrapper functions. - Remove unnecessary check for promises resolving multiple times. (By following the Promises/A+ spec, we know this will never happen.) - Switch from function expressions to (named) function declarations. Closes #15065
Commits on Sep 12, 2016
remove redundant link to ngOptions and add link to ngRepeat
Commits on Sep 15, 2016
Commits on Sep 16, 2016
Commits on Sep 19, 2016
Generally we don't use `ngInclude` any more, so this commit updates the example snippet to use component instead. Closes #15153
Reference: [JSON.stringify](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify). Closes #15156
Update the description of CSP, mainly regarding `unsafe-eval` and `unsafe-inline`. The way it was presented previously was slightly misleading as it indicated that these were rules forbidding certain things, when in fact it's a keyword in the CSP that disables the very rule that was described. The updated text clarifies this better. Closes #15142
Commits on Sep 21, 2016
`Resource.bind()`, which creates an new Resource class with the same propertiesexcept for the additional bound default parameters, was not passing the original Resource class' `options`, resulting in different behavior. This commit fixes it by passing the `options` when creating the new Resource class.
This reverts from commit c0b42f0
This reverts commit 90c08b8
…ax support This reverts commit b78539b
This reverts commit 296da4b
Commits on Sep 25, 2016
Improve the explanation of what a "pure function" is in simple words. The previous explanation could be confusing, especially since the term "idempotent" (here used in it's broader "Computer Science" meaning) is overloaded and has much stricter semantics in Mathematics or pure Functional Programming. Closes #15173
…rpolation Previoulsy, when the value of an `ngAttrXyz` attribute did not contain any interpolation, then the `xyz` attribute was never set. BTW, this commit adds a negligible overhead (since we have to set up a one-time watcher for example), but it is justifiable for someone that is using `ngAttrXyz` (instead of `xyz` directly). (There is also some irrelevant refactoring to remove unnecessary dependencies from tests.) Fixes #15133 Closes #15149
Commits on Sep 26, 2016
Commits on Sep 30, 2016
- **step_04:** `controllers is one file` --> `controllers in one file` - **step_06:** `.components.js` --> `.component.js` Closes #15197
Commits on Oct 05, 2016
Commits on Oct 06, 2016
Commits on Oct 07, 2016
Commits on Oct 08, 2016
Closes #15150
Commits on Oct 09, 2016
Commits on Oct 10, 2016
The parser always threw an error in the case of an invalid left-value assignment but it was an unhelpful: ``` Cannot set property 'undefined' of undefined ``` This commit provides a more meaningful error message, so it is not a breaking change. Closes #15234
This commit re-applies the related (previously reverted) commits. A follow-up commit will make the support opt-in in order to avoid a breaking change. Included commits: - 296da4b - `feat(input): add support for binding to input[type=range]` (previously reverted with 6a167e8) - b78539b - `fix(input[range]): correctly handle min/max; remove ngMin/ngMax support` (previously reverted with aa60491) - 90c08b8 - `feat(input[range]): support step` (previously reverted with 5b633d8)
Unified
Split
Showing
with
9,978 additions
and 9,594 deletions.
- +1 −0 .eslintrc-base.json
- +1 −2 .eslintrc-todo.json
- +6 −18 CHANGELOG.md
- +1 −1 Gruntfile.js
- +42 −9 README.md
- +1 −1 angularFiles.js
- +2 −2 benchmarks/largetable-bp/app.js
- +1 −1 benchmarks/ng-options-bp/app.js
- +1 −1 benchmarks/orderby-bp/app.js
- +2 −2 benchmarks/orderby-bp/bp.conf.js
- +1 −0 benchmarks/orderby-bp/jquery-noop.js
- +1 −1 changelog.js
- +1 −1 compare-master-to-stable.js
- +1 −1 docs/app/assets/js/search-worker.js
- +4 −4 docs/app/e2e/api-docs/api-pages.scenario.js
- +2 −2 docs/app/e2e/api-docs/provider-pages.scenario.js
- +3 −3 docs/app/e2e/api-docs/service-pages.scenario.js
- +3 −3 docs/app/e2e/app.scenario.js
- +1 −1 docs/app/src/docs.js
- +4 −4 docs/app/src/examples.js
- +4 −0 docs/app/src/versions.js
- +1 −1 docs/app/test/directivesSpec.js
- +3 −3 docs/app/test/docsSpec.js
- +1 −1 docs/config/index.js
- +1 −1 docs/config/processors/index-page.js
- +1 −1 docs/config/processors/keywords.js
- +1 −1 docs/config/processors/versions-data.js
- +1 −1 docs/config/services/deployments/debug.js
- +1 −1 docs/config/services/deployments/default.js
- +1 −1 docs/config/services/deployments/jquery.js
- +2 −2 docs/config/services/deployments/production.js
- +1 −1 docs/config/services/errorNamespaceMap.js
- +1 −1 docs/config/services/getMinerrInfo.js
- +1 −1 docs/config/services/getVersion.js
- +1 −1 docs/config/templates/indexPage.template.html
- +18 −0 docs/content/error/$compile/badrestrict.ngdoc
- +0 −71 docs/content/error/$compile/noident.ngdoc
- +23 −0 docs/content/error/$controller/ctrlreg.ngdoc
- +2 −1 docs/content/error/ng/areq.ngdoc
- +3 −2 docs/content/error/ngModel/numfmt.ngdoc
- +40 −19 docs/content/guide/$location.ngdoc
- +1 −1 docs/content/guide/component-router.ngdoc
- +1 −2 docs/content/guide/component.ngdoc
- +12 −9 docs/content/guide/concepts.ngdoc
- +1 −1 docs/content/guide/controller.ngdoc
- +1 −1 docs/content/guide/directive.ngdoc
- +2 −2 docs/content/guide/external-resources.ngdoc
- +4 −3 docs/content/guide/filter.ngdoc
- +4 −4 docs/content/guide/i18n.ngdoc
- +1 −1 docs/content/guide/services.ngdoc
- +1 −1 docs/content/tutorial/index.ngdoc
- +4 −2 docs/content/tutorial/step_03.ngdoc
- +1 −1 docs/content/tutorial/step_04.ngdoc
- +1 −1 docs/content/tutorial/step_06.ngdoc
- +9 −1 docs/gulpfile.js
- +10 −10 gdocs.js
- +0 −1 i18n/closure/numberSymbolsExt.js
- +19 −19 i18n/e2e/i18n-e2e.js
- +123 −123 i18n/spec/closureI18nExtractorSpec.js
- +2 −2 i18n/spec/converterSpec.js
- +2 −2 i18n/spec/parserSpec.js
- +5 −5 i18n/src/closureI18nExtractor.js
- +3 −3 i18n/src/closureSlurper.js
- +6 −6 karma-shared.conf.js
- +1 −1 lib/grunt/plugins.js
- +20 −20 lib/grunt/utils.js
- +1 −1 lib/grunt/validate-angular-files.js
- +2 −2 lib/versions/version-info.js
- +133 −441 npm-shrinkwrap.clean.json
- +696 −1,212 npm-shrinkwrap.json
- +5 −1 package.json
- +1 −1 scripts/npm/clean-shrinkwrap.js
- +1 −0 src/.eslintrc.json
- +19 −13 src/Angular.js
- +6 −4 src/AngularPublic.js
- +4 −4 src/auto/injector.js
- +18 −18 src/jqLite.js
- +3 −3 src/loader.js
- +2 −1 src/ng/anchorScroll.js
- +3 −3 src/ng/animate.js
- +1 −1 src/ng/browser.js
- +7 −5 src/ng/cacheFactory.js
- +157 −111 src/ng/compile.js
- +8 −3 src/ng/controller.js
- +2 −2 src/ng/directive/attrs.js
- +145 −79 src/ng/directive/input.js
- +2 −2 src/ng/directive/ngController.js
- +32 −26 src/ng/directive/ngCsp.js
- +4 −4 src/ng/directive/ngModel.js
- +7 −6 src/ng/directive/ngOptions.js
- +3 −3 src/ng/directive/ngPluralize.js
- +5 −5 src/ng/directive/ngRepeat.js
- +22 −6 src/ng/directive/ngSwitch.js
- +1 −1 src/ng/directive/ngTransclude.js
- +1 −1 src/ng/directive/validators.js
- +2 −2 src/ng/filter/filters.js
- +1 −1 src/ng/filter/limitTo.js
- +1 −1 src/ng/filter/orderBy.js
- +6 −4 src/ng/http.js
- +10 −10 src/ng/httpBackend.js
- +4 −4 src/ng/interpolate.js
- +45 −37 src/ng/location.js
- +15 −14 src/ng/parse.js
- +20 −34 src/ng/q.js
- +1 −2 src/ng/rootScope.js
- +5 −5 src/ng/sce.js
- +9 −3 src/ng/sniffer.js
- +2 −2 src/ng/urlUtils.js
- +3 −3 src/ngAnimate/animateCss.js
- +11 −11 src/ngAnimate/module.js
- +1 −1 src/ngAnimate/shared.js
- +3 −3 src/ngCookies/cookieWriter.js
- +19 −19 src/ngMessageFormat/messageFormatParser.js
- +4 −4 src/ngMessageFormat/messageFormatSelector.js
- +13 −13 src/ngMessageFormat/messageFormatService.js
- +1 −1 src/ngMessages/messages.js
- +26 −17 src/ngMock/angular-mocks.js
- +31 −27 src/ngResource/resource.js
- +2 −2 src/ngRoute/directive/ngView.js
- +2 −2 src/ngRoute/route.js
- +33 −34 src/ngSanitize/sanitize.js
- +1 −1 src/ngScenario/Application.js
- +18 −18 src/ngScenario/angular-bootstrap.js
- +1 −1 src/ngScenario/browserTrigger.js
- +24 −24 src/ngScenario/dsl.js
- +1 −1 src/ngScenario/output/Html.js
- +1 −0 test/.eslintrc.json
- +110 −113 test/AngularSpec.js
- +7 −7 test/BinderSpec.js
- +15 −15 test/auto/injectorSpec.js
- +6 −0 test/e2e/fixtures/version/index.html
- +57 −0 test/e2e/tests/version.spec.js
- +92 −57 test/helpers/matchers.js
- +3 −3 test/helpers/testabilityPatch.js
- +108 −102 test/jqLiteSpec.js
- +4 −4 test/loaderSpec.js
- +1 −1 test/minErrSpec.js
- +1 −1 test/modules/no_bootstrap.js
- +12 −0 test/ng/anchorScrollSpec.js
- +15 −15 test/ng/animateCssSpec.js
- +18 −18 test/ng/animateRunnerSpec.js
- +22 −22 test/ng/animateSpec.js
- +4 −4 test/ng/browserSpecs.js
- +2 −2 test/ng/cacheFactorySpec.js
- +5,596 −5,155 test/ng/compileSpec.js
- +23 −18 test/ng/controllerSpec.js
- +8 −8 test/ng/cookieReaderSpec.js
- +5 −5 test/ng/directive/booleanAttrsSpec.js
- +2 −2 test/ng/directive/formSpec.js
- +359 −171 test/ng/directive/inputSpec.js
- +1 −1 test/ng/directive/ngBindSpec.js
- +8 −8 test/ng/directive/ngClassSpec.js
- +1 −0 test/ng/directive/ngControllerSpec.js
- +3 −3 test/ng/directive/ngIncludeSpec.js
- +3 −3 test/ng/directive/ngInitSpec.js
- +5 −5 test/ng/directive/ngListSpec.js
- +13 −25 test/ng/directive/ngModelSpec.js
- +4 −4 test/ng/directive/ngNonBindableSpec.js
- +1 −1 test/ng/directive/ngOptionsSpec.js
- +64 −64 test/ng/directive/ngPluralizeSpec.js
- +30 −29 test/ng/directive/ngRepeatSpec.js
- +14 −14 test/ng/directive/ngSrcSpec.js
- +110 −3 test/ng/directive/ngSwitchSpec.js
- +11 −12 test/ng/directive/selectSpec.js
- +11 −11 test/ng/directive/validatorsSpec.js
- +1 −1 test/ng/documentSpec.js
- +3 −3 test/ng/filter/filterSpec.js
- +65 −65 test/ng/filter/filtersSpec.js
- +28 −28 test/ng/filter/limitToSpec.js
- +13 −13 test/ng/filter/orderBySpec.js
- +11 −11 test/ng/httpBackendSpec.js
- +3 −3 test/ng/httpSpec.js
- +29 −29 test/ng/interpolateSpec.js
- +5 −5 test/ng/intervalSpec.js
- +59 −18 test/ng/locationSpec.js
- +5 −5 test/ng/logSpec.js
- +229 −215 test/ng/parseSpec.js
- +44 −44 test/ng/qSpec.js
- +1 −1 test/ng/rafSpec.js
- +18 −18 test/ng/rootScopeSpec.js
- +46 −46 test/ng/sanitizeUriSpec.js
- +14 −14 test/ng/sceSpecs.js
- +22 −0 test/ng/snifferSpec.js
- +5 −5 test/ng/timeoutSpec.js
- +5 −5 test/ng/urlUtilsSpec.js
- +1 −1 test/ng/windowSpec.js
- +35 −35 test/ngAnimate/animateCssDriverSpec.js
- +112 −112 test/ngAnimate/animateCssSpec.js
- +1 −1 test/ngAnimate/animateJsDriverSpec.js
- +15 −15 test/ngAnimate/animateJsSpec.js
- +7 −7 test/ngAnimate/animateSpec.js
- +1 −1 test/ngAnimate/animationHelperFunctionsSpec.js
- +22 −22 test/ngAnimate/animationSpec.js
- +3 −3 test/ngAnimate/integrationSpec.js
- +2 −2 test/ngAnimate/ngAnimateSwapSpec.js
- +1 −1 test/ngAnimate/rafSchedulerSpec.js
- +41 −41 test/ngAria/ariaSpec.js
- +9 −9 test/ngCookies/cookieWriterSpec.js
- +4 −4 test/ngCookies/cookiesSpec.js
- +95 −95 test/ngMessageFormat/messageFormatSpec.js
- +17 −17 test/ngMessages/messagesSpec.js
- +79 −79 test/ngMock/angular-mocksSpec.js
- +102 −28 test/ngResource/resourceSpec.js
- +1 −1 test/ngRoute/directive/ngViewSpec.js
- +3 −2 test/ngRoute/routeSpec.js
- +14 −14 test/ngSanitize/filter/linkySpec.js
- +13 −2 test/ngSanitize/sanitizeSpec.js
- +4 −4 test/ngScenario/ApplicationSpec.js
- +1 −1 test/ngScenario/RunnerSpec.js
- +4 −4 test/ngScenario/ScenarioSpec.js
- +2 −2 test/ngScenario/dslSpec.js
- +4 −4 test/ngScenario/e2e/widgets-scenario.js
- +1 −1 test/ngScenario/matchersSpec.js
- +1 −1 test/ngScenario/output/HtmlSpec.js
- +1 −1 validate-commit-msg.spec.js
| @@ -104,6 +104,7 @@ | ||
| "no-spaced-func": "error", | ||
| "no-trailing-spaces": "error", | ||
| "no-unneeded-ternary": "error", | ||
| "quotes": ["error", "single"], | ||
| "semi-spacing": "error", | ||
| "semi": "error", | ||
| "space-before-blocks": ["error", "always"], | ||
| @@ -20,7 +20,6 @@ | ||
| "key-spacing": ["error", { "beforeColon": false, "afterColon": true, "mode": "minimum" }], | ||
| "object-curly-spacing": ["error", "never"], | ||
| "object-property-newline": ["error", { "allowMultiplePropertiesPerLine": true }], | ||
| "operator-linebreak": ["error", "after", { "overrides": { "?": "before", ":": "before" }}], | ||
| "quotes": ["error", "single"] | ||
| "operator-linebreak": ["error", "after", { "overrides": { "?": "before", ":": "before" }}] | ||
| } | ||
| } | ||
| @@ -86,7 +86,7 @@ to make the fixes available to people that still need IE8 support._ | ||
| - secure `link[href]` as a `RESOURCE_URL`s in `$sce` | ||
| ([f35f334b](https://github.com/angular/angular.js/commit/f35f334bd3197585bdf034f4b6d9ffa3122dac62), | ||
| [#14687](https://github.com/angular/angular.js/issues/14687)) | ||
| - properly sanitize `xlink:href` attribute interoplation | ||
| - properly sanitize `xlink:href` attribute interpolation | ||
| ([f2fa1ed8](https://github.com/angular/angular.js/commit/f2fa1ed83d18d4e79a36f8c0db1c2524d762e513), | ||
| [2687c261](https://github.com/angular/angular.js/commit/2687c26140585d9e3716f9f559390f5d8d598fdf)) | ||
| - **ngSanitize:** blacklist the attribute `usemap` as it can be used as a security exploit | ||
| @@ -137,6 +137,9 @@ content, which is a security risk. | ||
| - cope with `$onChanges` hooks throwing | ||
| ([3749c858](https://github.com/angular/angular.js/commit/3749c85829406ca57cc5729e80696c7f34134068), | ||
| [#14444](https://github.com/angular/angular.js/issues/14444), [#14463](https://github.com/angular/angular.js/issues/14463)) | ||
| - **$location:** initialize `$$absUrl` to empty string | ||
| ([294d6793f](https://github.com/angular/angular.js/commit/294d6793fd0e0781a257e35a165e0c6fde082fe7), | ||
| [#11091](https://github.com/angular/angular.js/issues/11091), [#13565](https://github.com/angular/angular.js/issues/13565), [#14488](https://github.com/angular/angular.js/issues/14488)) | ||
| - **$parse:** allow arguments to contain filter chains | ||
| ([cc6dcb4b](https://github.com/angular/angular.js/commit/cc6dcb4bc28aadff4f62d76d6451b0f80b928e69), | ||
| [#4175](https://github.com/angular/angular.js/issues/4175), [#4168](https://github.com/angular/angular.js/issues/4168), [#14720](https://github.com/angular/angular.js/issues/14720)) | ||
| @@ -506,7 +509,7 @@ for more info. | ||
| - prevent assignment on constructor properties | ||
| ([f47e2180](https://github.com/angular/angular.js/commit/f47e218006029f39b4785d820b430de3a0eebcb0), | ||
| [#13417](https://github.com/angular/angular.js/issues/13417)) | ||
| - preserve expensive checks when runnning `$eval` inside an expression | ||
| - preserve expensive checks when running `$eval` inside an expression | ||
| ([96d62cc0](https://github.com/angular/angular.js/commit/96d62cc0fc77248d7e3ec4aa458bac0d3e072629)) | ||
| - copy `inputs` for expressions with expensive checks | ||
| ([0b7fff30](https://github.com/angular/angular.js/commit/0b7fff303f46202bbae1ff3ca9d0e5fa76e0fc9a)) | ||
| @@ -628,7 +631,7 @@ changes section for more information | ||
| - handle boolean attributes in `@` bindings | ||
| ([db5e0ffe](https://github.com/angular/angular.js/commit/db5e0ffe124ac588f01ef0fe79efebfa72f5eec7), | ||
| [#13767](https://github.com/angular/angular.js/issues/13767), [#13769](https://github.com/angular/angular.js/issues/13769)) | ||
| - **$parse:** Preserve expensive checks when runnning $eval inside an expression | ||
| - **$parse:** Preserve expensive checks when running $eval inside an expression | ||
| ([acfda102](https://github.com/angular/angular.js/commit/acfda1022d23ecaea34bbc8931588a0715b3ab03)) | ||
| - **dateFilter:** follow the CLDR on pattern escape sequences | ||
| ([1ab4e444](https://github.com/angular/angular.js/commit/1ab4e44443716c33cd857dcb1098d20580dbb0cc), | ||
| @@ -1008,26 +1011,20 @@ report any regressions or other issues you find as soon as possible. | ||
|
|
||
| - **$parse:** provide a mechanism to access the locals object, `$locals` | ||
| ([0ea53503](https://github.com/angular/angular.js/commit/0ea535035a3a1a992948490c3533bffb83235052)) | ||
|
|
||
| - **$resource:** add proper support for cancelling requests, `$cancelRequest()` | ||
| ([98528be3](https://github.com/angular/angular.js/commit/98528be311b48269ba0e15ba4e3e2ad9b89693a9), | ||
| [#9332](https://github.com/angular/angular.js/issues/9332), [#13050](https://github.com/angular/angular.js/issues/13050), [#13058](https://github.com/angular/angular.js/issues/13058), [#13210](https://github.com/angular/angular.js/issues/13210)) | ||
|
|
||
| - **ngAnimate:** provide ng-[event]-prepare class for structural animations | ||
| ([6e18b50a](https://github.com/angular/angular.js/commit/6e18b50a5b168848cc526081b0a2a16075ee44bd)) | ||
|
|
||
| - **ngLocale:** add support for standalone months | ||
| ([96c73a06](https://github.com/angular/angular.js/commit/96c73a0672f0e46ae9285c482b057bd03ce135ba), | ||
| [#3744](https://github.com/angular/angular.js/issues/3744), [#10247](https://github.com/angular/angular.js/issues/10247), [#12642](https://github.com/angular/angular.js/issues/12642), [#12844](https://github.com/angular/angular.js/issues/12844)) | ||
|
|
||
| - **ngMock:** destroy $rootScope after each test | ||
| ([b75c0d8d](https://github.com/angular/angular.js/commit/b75c0d8d0549261ece551210a11d8be48c3ab3cc), | ||
| [#13433](https://github.com/angular/angular.js/issues/13433)) | ||
|
|
||
| - **ngTransclude:** don't overwrite the contents with an unfilled optional slot | ||
| ([0812af49](https://github.com/angular/angular.js/commit/0812af49bd4f4fad4067603ff64dbe720bd6e3e5), | ||
| [#13426](https://github.com/angular/angular.js/issues/13426)) | ||
|
|
||
| - **ngView:** reference resolved locals in scope, `resolveAs: '$resolve'` | ||
| ([983b0598](https://github.com/angular/angular.js/commit/983b0598121a8c5a3a51a30120e114d7e3085d4d), | ||
| [#13400](https://github.com/angular/angular.js/issues/13400)) | ||
| @@ -1044,30 +1041,24 @@ report any regressions or other issues you find as soon as possible. | ||
| - support merging special attribute names in `replace` directives | ||
| ([a5ff651a](https://github.com/angular/angular.js/commit/a5ff651a59933c2c43b81642454ee458f98e1401), | ||
| [#13317](https://github.com/angular/angular.js/issues/13317), [#13318](https://github.com/angular/angular.js/issues/13318)) | ||
|
|
||
| - **$http:** throw if url passed is not a string | ||
| ([6628b4f1](https://github.com/angular/angular.js/commit/6628b4f1e5835d997290881c6ba394547883a516), | ||
| [#12925](https://github.com/angular/angular.js/issues/12925), [#13444](https://github.com/angular/angular.js/issues/13444)) | ||
|
|
||
| - **$parse:** | ||
| - prevent assignment on constructor properties | ||
| ([5a674f3b](https://github.com/angular/angular.js/commit/5a674f3bb9d1118d11b333e3b966c01a571c09e6), | ||
| [#13417](https://github.com/angular/angular.js/issues/13417)) | ||
| - handle interceptors with `undefined` expressions | ||
| ([4473b81c](https://github.com/angular/angular.js/commit/4473b81cdaf16c5509ac53d80b9bdfb0a7ac5f30)) | ||
|
|
||
| - **$sanitize:** blacklist SVG `<use>` elements | ||
| ([7a668cdd](https://github.com/angular/angular.js/commit/7a668cdd7d08a7016883eb3c671cbcd586223ae8), | ||
| [#13453](https://github.com/angular/angular.js/issues/13453)) | ||
|
|
||
| - **formatNumber:** cope with large and small number corner cases | ||
| ([6a0686d4](https://github.com/angular/angular.js/commit/6a0686d434c41445c50b2d9669073802ede77b3b), | ||
| [#13394](https://github.com/angular/angular.js/issues/13394), [#8674](https://github.com/angular/angular.js/issues/8674), [#12709](https://github.com/angular/angular.js/issues/12709), [#8705](https://github.com/angular/angular.js/issues/8705), [#12707](https://github.com/angular/angular.js/issues/12707), [#10246](https://github.com/angular/angular.js/issues/10246), [#10252](https://github.com/angular/angular.js/issues/10252)) | ||
|
|
||
| - **input:** add missing chars to URL validation regex | ||
| ([e4bb8387](https://github.com/angular/angular.js/commit/e4bb8387952069cca9da06bbc5c87ae576c2bf6f), | ||
| [#13379](https://github.com/angular/angular.js/issues/13379), [#13460](https://github.com/angular/angular.js/issues/13460)) | ||
|
|
||
| - **ngAnimate:** | ||
| - consider options.delay value for closing timeout | ||
| ([7ffb2d3c](https://github.com/angular/angular.js/commit/7ffb2d3c17643303a51eb4e324c365af70fe3824), | ||
| @@ -1081,15 +1072,12 @@ report any regressions or other issues you find as soon as possible. | ||
| - do not alter the provided options data | ||
| ([193153c3](https://github.com/angular/angular.js/commit/193153c3d391338a859cb7788ef32a8af05fb920), | ||
| [#13040](https://github.com/angular/angular.js/issues/13040), [#13175](https://github.com/angular/angular.js/issues/13175)) | ||
|
|
||
| - **ngMock:** clear out `$providerInjector` after each test | ||
| ([a72c12bd](https://github.com/angular/angular.js/commit/a72c12bd7052da9f60da74625409374342b50b73), | ||
| [#13397](https://github.com/angular/angular.js/issues/13397), [#13416](https://github.com/angular/angular.js/issues/13416)) | ||
|
|
||
| - **ngOptions:** don't $dirty multiple select after compilation | ||
| ([c7a2028a](https://github.com/angular/angular.js/commit/c7a2028ab38cdfc4d956c50b6f41cbccef302165), | ||
| [#13211](https://github.com/angular/angular.js/issues/13211), [#13326](https://github.com/angular/angular.js/issues/13326)) | ||
|
|
||
| - **ngTransclude:** | ||
| - don't replace existing content if no transcluded content exists | ||
| ([c3ae6ed7](https://github.com/angular/angular.js/commit/c3ae6ed78e145a9b0c13de7ef95852ba3c467551), | ||
| @@ -205,7 +205,7 @@ module.exports = function(grunt) { | ||
| dest: 'build/angular-parse-ext.js', | ||
| src: util.wrap(files['angularModules']['ngParseExt'], 'module') | ||
| }, | ||
| "promises-aplus-adapter": { | ||
| 'promises-aplus-adapter': { | ||
| dest:'tmp/promises-aplus-adapter++.js', | ||
| src:['src/ng/q.js', 'lib/promises-aplus/promises-aplus-test-adapter.js'] | ||
| } | ||
| @@ -51,24 +51,57 @@ We've set up a separate document for our [contribution guidelines](https://githu | ||
|
|
||
| What to use AngularJS for and when to use it | ||
| --------- | ||
| AngularJS is the next generation framework where each component is designed to work with every other component in an interconnected way like a well-oiled machine. AngularJS is JavaScript MVC made easy and done right. (Well it is not really MVC, read on, to understand what this means.) | ||
| AngularJS is the next generation framework where each component is designed to work with every other | ||
| component in an interconnected way like a well-oiled machine. AngularJS is JavaScript MVC made easy | ||
| and done right. (Well it is not really MVC, read on, to understand what this means.) | ||
|
|
||
| #### MVC, no, MV* done the right way! | ||
| MVC, short for Model-View-Controller, is a design pattern, i.e. how the code should be organized and how the different parts of an application separated for proper readability and debugging. Model is the data and the database. View is the user interface and what the user sees. Controller is the main link between Model and View. These are the three pillars of major programming frameworks present on the market today. On the other hand AngularJS works on MV*, short for Model-View-_Whatever_. The _Whatever_ is AngularJS's way of telling that you may create any kind of linking between the Model and the View here. | ||
|
|
||
| Unlike other frameworks in any programming language, where MVC, the three separate components, each one has to be written and then connected by the programmer, AngularJS helps the programmer by asking him/her to just create these and everything else will be taken care of by AngularJS. | ||
| MVC, short for Model-View-Controller, is a design pattern, i.e. how the code should be organized and | ||
| how the different parts of an application separated for proper readability and debugging. Model is | ||
| the data and the database. View is the user interface and what the user sees. Controller is the main | ||
| link between Model and View. These are the three pillars of major programming frameworks present on | ||
| the market today. On the other hand AngularJS works on MV*, short for Model-View-_Whatever_. The | ||
| _Whatever_ is AngularJS's way of telling that you may create any kind of linking between the Model | ||
| and the View here. | ||
|
|
||
| Unlike other frameworks in any programming language, where MVC, the three separate components, each | ||
| one has to be written and then connected by the programmer, AngularJS helps the programmer by asking | ||
| him/her to just create these and everything else will be taken care of by AngularJS. | ||
|
|
||
| #### Interconnection with HTML at the root level | ||
| AngularJS uses HTML to define the user's interface. AngularJS also enables the programmer to write new HTML tags (AngularJS Directives) and increase the readability and understandability of the HTML code. Directives are AngularJS’s way of bringing additional functionality to HTML. Directives achieve this by enabling us to invent our own HTML elements. This also helps in making the code DRY (Don't Repeat Yourself), which means once created, a new directive can be used anywhere within the application. | ||
| AngularJS uses HTML to define the user's interface. AngularJS also enables the programmer to write | ||
| new HTML tags (AngularJS Directives) and increase the readability and understandability of the HTML | ||
| code. Directives are AngularJS’s way of bringing additional functionality to HTML. Directives | ||
| achieve this by enabling us to invent our own HTML elements. This also helps in making the code DRY | ||
| (Don't Repeat Yourself), which means once created, a new directive can be used anywhere within the | ||
| application. | ||
|
|
||
| HTML is also used to determine the wiring of the app. Special attributes in the HTML determine where | ||
| to load the app, which components or controllers to use for each element, etc. We specify "what" | ||
| gets loaded, but not "how". This declarative approach greatly simplifies app development in a sort | ||
| of WYSIWYG way. Rather than spending time on how the program flows and orchestrating the various | ||
| moving parts, we simply define what we want and Angular will take care of the dependencies. | ||
|
|
||
| #### Data Handling made simple | ||
| Data and Data Models in AngularJS are plain JavaScript objects and one can add and change properties directly on it and loop over objects and arrays at will. | ||
| Data and Data Models in AngularJS are plain JavaScript objects and one can add and change properties | ||
| directly on it and loop over objects and arrays at will. | ||
|
|
||
| #### Two-way Data Binding | ||
| One of AngularJS's strongest features. Two-way Data Binding means that if something changes in the Model, the change gets reflected in the View instantaneously, and the same happens the other way around. This is also referred to as Reactive Programming, i.e. suppose `a = b + c` is being programmed and after this, if the value of `b` and/or `c` is changed then the value of `a` will be automatically updated to reflect the change. AngularJS uses its "scopes" as a glue between the Model and View and makes these updates in one available for the other. | ||
| One of AngularJS's strongest features. Two-way Data Binding means that if something changes in the | ||
| Model, the change gets reflected in the View instantaneously, and the same happens the other way | ||
| around. This is also referred to as Reactive Programming, i.e. suppose `a = b + c` is being | ||
| programmed and after this, if the value of `b` and/or `c` is changed then the value of `a` will be | ||
| automatically updated to reflect the change. AngularJS uses its "scopes" as a glue between the Model | ||
| and View and makes these updates in one available for the other. | ||
|
|
||
| #### Less Written Code and Easily Maintainable Code | ||
| Everything in AngularJS is created to enable the programmer to end up writing less code that is easily maintainable and readable by any other new person on the team. Believe it or not, one can write a complete working two-way data binded application in less than 10 lines of code. Try and see for yourself! | ||
| Everything in AngularJS is created to enable the programmer to end up writing less code that is | ||
| easily maintainable and readable by any other new person on the team. Believe it or not, one can | ||
| write a complete working two-way data binded application in less than 10 lines of code. Try and see | ||
| for yourself! | ||
|
|
||
| #### Testing Ready | ||
| AngularJS has Dependency Injection, i.e. it takes care of providing all the necessary dependencies to its controllers whenever required. This helps in making the AngularJS code ready for unit testing by making use of mock dependencies created and injected. This makes AngularJS more modular and easily testable thus in turn helping a team create more robust applications. | ||
| AngularJS has Dependency Injection, i.e. it takes care of providing all the necessary dependencies | ||
| to its controllers and services whenever required. This helps in making the AngularJS code ready for | ||
| unit testing by making use of mock dependencies created and injected. This makes AngularJS more | ||
| modular and easily testable thus in turn helping a team create more robust applications. | ||
| @@ -209,7 +209,7 @@ var angularFiles = { | ||
| 'build/docs/docs-scenario.js' | ||
| ], | ||
|
|
||
| "karmaModules": [ | ||
| 'karmaModules': [ | ||
| 'build/angular.js', | ||
| '@angularSrcModules', | ||
| 'test/modules/no_bootstrap.js', | ||
| @@ -23,9 +23,9 @@ app.controller('DataController', function DataController($scope, $rootScope) { | ||
| $scope.numberOfBindings = totalRows * totalColumns * 2 + totalRows + 1; | ||
| $scope.numberOfWatches = '?'; | ||
|
|
||
| /* @this */ | ||
| /** @this */ | ||
| function iGetter() { return this.i; } | ||
| /* @this */ | ||
| /** @this */ | ||
| function jGetter() { return this.j; } | ||
|
|
||
| for (var i = 0; i < totalRows; i++) { | ||
| @@ -1,4 +1,4 @@ | ||
| "use strict"; | ||
| 'use strict'; | ||
|
|
||
| /* globals angular, benchmarkSteps */ | ||
|
|
||
| @@ -7,7 +7,7 @@ app.controller('DataController', function DataController($rootScope, $scope) { | ||
| this.rows = []; | ||
| var self = this; | ||
|
|
||
| $scope.benchmarkType = 'basic'; | ||
| $scope.benchmarkType = 'baseline'; | ||
|
|
||
| $scope.rawProperty = function(key) { | ||
| return function(item) { | ||
| @@ -6,8 +6,8 @@ module.exports = function(config) { | ||
| config.set({ | ||
| scripts: [ | ||
| { | ||
| "id": "jquery", | ||
| "src": "jquery-noop.js" | ||
| 'id': 'jquery', | ||
| 'src': 'jquery-noop.js' | ||
| }, { | ||
| id: 'angular', | ||
| src: '/build/angular.js' | ||
| @@ -0,0 +1 @@ | ||
| // Override me with ?jquery=/bower_components/jquery/dist/jquery.js |
| @@ -160,7 +160,7 @@ var writeChangelog = function(stream, commits, version) { | ||
| if (commit.breaking) { | ||
| sections.breaks[component] = sections.breaks[component] || []; | ||
| sections.breaks[component].push({ | ||
| subject: util.format("due to %s,\n %s", linkToCommit(commit.hash), commit.breaking), | ||
| subject: util.format('due to %s,\n %s', linkToCommit(commit.hash), commit.breaking), | ||
| hash: commit.hash, | ||
| closes: [] | ||
| }); | ||
| @@ -21,7 +21,7 @@ var exec = function(cmd) { | ||
| }; | ||
|
|
||
| var andThen = function(fn, after) { | ||
| return /* @this */ function() { | ||
| return /** @this */ function() { | ||
| return fn.apply(this, arguments).then(after); | ||
| }; | ||
| }; | ||
| @@ -8,7 +8,7 @@ importScripts('../components/lunr.js-0.5.12/lunr.min.js'); | ||
|
|
||
| // Create the lunr index - the docs should be an array of object, each object containing | ||
| // the path and search terms for a page | ||
| var index = lunr(/* @this */function() { | ||
| var index = lunr(/** @this */function() { | ||
| this.ref('path'); | ||
| this.field('titleWords', {boost: 50}); | ||
| this.field('members', {boost: 40}); | ||
| @@ -1,10 +1,10 @@ | ||
| 'use strict'; | ||
|
|
||
| describe("doc.angularjs.org", function() { | ||
| describe('doc.angularjs.org', function() { | ||
|
|
||
| describe("API pages", function() { | ||
| describe('API pages', function() { | ||
|
|
||
| it("should display links to code on GitHub", function() { | ||
| it('should display links to code on GitHub', function() { | ||
| browser.get('build/docs/index.html#!/api/ng/service/$http'); | ||
| expect(element(by.css('.improve-docs')).getAttribute('href')).toMatch(/https?:\/\/github\.com\/angular\/angular\.js\/edit\/.+\/src\/ng\/http\.js/); | ||
|
|
||
| @@ -38,7 +38,7 @@ describe("doc.angularjs.org", function() { | ||
| expect(code.getText()).toContain('guest!!!'); | ||
| }); | ||
|
|
||
| it("should trim indentation from code blocks", function() { | ||
| it('should trim indentation from code blocks', function() { | ||
| browser.get('build/docs/index.html#!/api/ng/type/$rootScope.Scope'); | ||
|
|
||
| var codeBlocks = element.all(by.css('pre > code.lang-js')); | ||
Oops, something went wrong.