https://github.com/angular/angular

sort by:
Revision Author Date Message Commit Date
73c7882 release: cut the v10.1.3 release 23 September 2020, 18:54:47 UTC
32e32e5 refactor(dev-infra): simplify runBenchmark (#38941) * Make url and params optional in runBenchmark * Make url optional in openBrowser * Remove unused code from runBenchmark PR Close #38941 22 September 2020, 22:05:34 UTC
0dda8bf refactor(zone.js): remove usages of blacklist related to UNPATCHED_EVENTS (#38930) Remove usages of blacklist around UNPATCHED_EVENTS configuration PR Close #38930 22 September 2020, 22:05:01 UTC
8db865d docs: Update titles to getting started topics (#38887) The topics for our getting started tutorial are inconsistent. This change makes the titles consistent and easier to read. PR Close #38887 21 September 2020, 23:33:29 UTC
667c10a ci: Update payload size on 10.1.x to be correct (#38923) Update payload size on 10.1.x to be correct after changing in 04d0aa6781a38ed8769c53fcc5d13304c4300f95. PR Close #38923 21 September 2020, 23:26:24 UTC
0286233 docs: change wrong default app module by ng new (#38549) In bootstrapping.md the default AppModule has some extra imports which are not generated by default in ng new removed those extra imports and add them at appropriate place. PR Close #38549 21 September 2020, 19:25:29 UTC
8f523c1 refactor(compiler): simplify visitor logic for attributes (#38899) The logic for computing identifiers, specifically for bound attributes can be simplified by using the value span of the binding rather than the source span. PR Close #38899 21 September 2020, 19:23:59 UTC
790e483 fix(docs-infra): remove scrollbar styles for accessibility (#38852) This commit removes the scrollbar styles so that the default styles in the browser render. This widens the webkit scroll bar. This makes it easier to grab the scrollbar using assistive technology and devices, and provides a wider target for those who have dexterity issues. By removing these styles, We will no longer have to maintain custom scrollbars specific to WebKit and they will be accessible by default. PR Close #38852 21 September 2020, 19:22:08 UTC
a7650b0 test(docs-infra): replace deprecated `ReflectiveInjector` with `Injector` (#38897) This commit replaces the old and slow ReflectiveInjector that was deprecated in v5 with the new Injector. PR Close #38897 21 September 2020, 19:21:27 UTC
04d0aa6 revert: feat(router): better warning message when a router outlet has not been instantiated (#38920) This reverts commit [1609815]. The warning that was added created more confusion than it solved and also warned for valid use-cases. PR Close #38920 21 September 2020, 19:18:45 UTC
7d5b515 docs: Grammar fixes (#38900) Changed several period into colons to be consistent throughout the doc. Changed "If don't add the interface..." to "If _you_ don't add the interface..." PR Close #38900 18 September 2020, 23:52:52 UTC
27a6e5a ci: do not require g3 checks for the changes in `packages/zone.js/dist` folder (#38901) This commit updates ngbot config to avoid requesting google3 presubmit for the changes in the `packages/zone.js/dist` folder (which is not synced into google3). PR Close #38901 18 September 2020, 23:48:17 UTC
2700d88 build: update to latest version of yarn (#38869) Update the vendored version of yarn to the latest version. PR Close #38869 18 September 2020, 23:47:34 UTC
3902ec0 fix(http): Fix error message when we call jsonp without importing HttpClientJsonpModule (#38756) Currently, when we call jsonp method without importing HttpClientJsonpModule, an error message appears saying 'Attempted to construct Jsonp request without JsonpClientModule installed.' instance of 'Attempted to construct Jsonp request without HttpClientJsonpModule installed.' PR Close #38756 18 September 2020, 18:20:37 UTC
6f579b2 feat(dev-infra): output the number of new and fixed cycles (#38805) This commit adds a logic to ouput the number of new and fixed cycles after running circular dependency checker. This information is useful to better understand an impact of changes in case the number of new/fixed cycles is relatively big. PR Close #38805 18 September 2020, 18:20:08 UTC
c4a7516 refactor(core): reduce the number of circular deps (#38805) This commit updates several import statements in the core package to decrease the number of cycles detected by the dependency checker tool. PR Close #38805 18 September 2020, 18:20:08 UTC
33055da fix(zone.js): should invoke xhr send task when no response error occurs (#38836) Close #38795 in the XMLHttpRequest patch, when get `readystatechange` event, zone.js try to invoke `load` event listener first, then call `invokeTask` to finish the `XMLHttpRequest::send` macroTask, but if the request failed because the server can not be reached, the `load` event listener will not be invoked, so the `invokeTask` of the `XMLHttpRequest::send` will not be triggered either, so we will have a non finished macroTask there which will make the Zone not stable, also memory leak. So in this PR, if the `XMLHttpRequest.status = 0` when we get the `readystatechange` event, that means something wents wrong before we reached the server, we need to invoke the task to finish the macroTask. PR Close #38836 18 September 2020, 18:19:37 UTC
fb163df fix(dev-infra): skip husky git commit hooks while merging pull requests (#38888) During the merge process, all validations have already been completed so git commit hooks can be safely skipped. This additionally, prevents errors from occuring which would be caused the commit hooks executing, such as when yarn updates and then yarn commands are unable to run within the same process. PR Close #38888 18 September 2020, 18:14:58 UTC
6b05dc4 refactor(core): remove unused imports (#38818) This commit removes some unused imports from the spec files. PR Close #38818 18 September 2020, 15:03:51 UTC
093c3a1 fix(ngcc): fix compilation of `ChangeDetectorRef` in pipe constructors (#38892) In #38666 we changed how ngcc deals with type expressions, where it would now always emit the original type expression into the generated code as a "local" type value reference instead of synthesizing new imports using an "imported" type value reference. This was done as a fix to properly deal with renamed symbols, however it turns out that the compiler has special handling for certain imported symbols, e.g. `ChangeDetectorRef` from `@angular/core`. The "local" type value reference prevented this special logic from being hit, resulting in incorrect compilation of pipe factories. This commit fixes the issue by manually inspecting the import of the type expression, in order to return an "imported" type value reference. By manually inspecting the import we continue to handle renamed symbols. Fixes #38883 PR Close #38892 18 September 2020, 15:02:50 UTC
a0756e9 refactor(compiler): replace Comment nodes with leadingComments property (#38811) Common AST formats such as TS and Babel do not use a separate node for comments, but instead attach comments to other AST nodes. Previously this was worked around in TS by creating a `NotEmittedStatement` AST node to attach the comment to. But Babel does not have this facility, so it will not be a viable approach for the linker. This commit refactors the output AST, to remove the `CommentStmt` and `JSDocCommentStmt` nodes. Instead statements have a collection of `leadingComments` that are rendered/attached to the final AST nodes when being translated or printed. PR Close #38811 18 September 2020, 15:01:29 UTC
d8657dd docs: updating the text of user input page to reflect real location of the forms page (#38802) PR Close #38802 18 September 2020, 15:00:44 UTC
2f71995 Update aio/content/marketing/events.json (#38874) Co-authored-by: George Kalpakas <kalpakas.g@gmail.com> PR Close #38874 18 September 2020, 15:00:02 UTC
32a8713 docs: add upcoming angular conferences (#38874) PR Close #38874 18 September 2020, 14:59:58 UTC
0958a8d docs: drop `newEvent()` compatibility function (#37251) Because PhantomJS has been deprecated since March 2018, and `newEvent` is very confusing for newcomers that read the testing documentation, we remove it entirely, and instead assume most, if not all, newcomers will run tests in Chrome as it is the default. Fixes #23370 PR Close #37251 17 September 2020, 16:31:23 UTC
e64c0c3 fix(dev-infra): handle no caretaker config being defined (#38862) Properly handle cases where no caretaker config is provided to ng-dev commands PR Close #38862 16 September 2020, 22:22:13 UTC
7302778 docs(forms): fix grammar in first sentence of reset function docs (#38872) PR Close #38872 16 September 2020, 22:20:33 UTC
674620a docs: fix typo in architecture.md guide (#38853) PR Close #38853 16 September 2020, 22:19:47 UTC
997713e docs(bazel): fix typo in BUILD.bazel comments (#38054) Update BUILD.bazel PR Close #38054 16 September 2020, 22:15:23 UTC
234e5af test(docs-infra): simplify `EventsComponent` tests and add more test cases (#36517) This commit simplifies the tests of `EventsComponent` (by introducing a `createMockEvent()` helper and getting rid of the irrelevant `Event` fields) and adds tests for some more usecases. It also makes the tests more robust by using Jasmine's `Clock` to mock the current date. PR Close #36517 16 September 2020, 22:14:32 UTC
e43c701 refactor(docs-infra): remove tooltip from links same as name (#36517) In the events.json file most of tooltips are same as name so there were of no use, as they were providing no extra information. So, removed them from the events.json file PR Close #36517 16 September 2020, 22:14:30 UTC
2e1264f feat(docs-infra): created new widget for events page (#36517) Data in events page was hardcoded and it is manually moved in the table. Created a new events widget which will automatically move past and upcoming events from events.json (`aio/content/marketing/events.json`) file to the relevant table in the events tab PR Close #36517 16 September 2020, 22:14:27 UTC
a89dcba test(docs-infra): improve typeahead example and add unit test (#34190) This commit improves the typeahead example, by using the emitted input value. It also adds a unit test to ensure that the example is working as intended. PR Close #34190 16 September 2020, 22:13:11 UTC
bd9f441 test(docs-infra): add unit tests for rxjs examples (#34190) This commit adds missing unit tests for all rxjs examples from the docs. Closes #28017 PR Close #34190 16 September 2020, 22:13:08 UTC
fbcb66e release: cut the v10.1.2 release 16 September 2020, 21:38:02 UTC
3d94919 refactor(dev-infra): refactor commit-message files (#38845) Refactor the commit-message files to be consistent with how other ng-dev tooling is structured. PR Close #38845 15 September 2020, 23:05:46 UTC
af3b401 docs: add ngc to glossary (#36781) ngc angular compiler was not mentioned in the glossary. Glossary should contain the relevant terms in angular which are hard to get. So, added a small defination of ngc to the glossary PR Close #36781 15 September 2020, 18:29:56 UTC
e4c12c8 test(ngcc): load standard files only once (#38840) In the integration test suite of ngcc, we load a set of files from `node_modules` into memory. This includes the `typescript` package and `@angular` scoped packages, which account for a large number of large files that needs to be loaded from disk. This commit moves this work to the top-level, such that it doesn't have to be repeated in all tests. PR Close #38840 15 September 2020, 18:23:28 UTC
ea36466 perf(ngcc): reduce maximum worker count (#38840) Recent optimizations to ngcc have significantly reduced the total time it takes to process `node_modules`, to such extend that sharding across multiple processes has become less effective. Previously, running ngcc asynchronously would allow for up to 8 workers to be allocated, however these workers have to repeat work that could otherwise be shared. Because ngcc is now able to reuse more shared computations, the overhead of multiple workers is increased and therefore becomes less effective. As an additional benefit, having fewer workers requires less memory and less startup time. To give an idea, using the following test setup: ```bash npx @angular/cli new perf-test cd perf-test yarn ng add @angular/material ./node_modules/.bin/ngcc --properties es2015 module main \ --first-only --create-ivy-entry-points ``` We observe the following figures on CI: | | 10.1.1 | PR #38840 | | ----------------- | --------- | --------- | | Sync | 85s | 25s | | Async (8 workers) | 22s | 16s | | Async (4 workers) | - | 11s | In addition to changing the default number of workers, ngcc will now use the environment variable `NGCC_MAX_WORKERS` that may be configured to either reduce or increase the number of workers. PR Close #38840 15 September 2020, 18:23:24 UTC
58411e7 perf(ngcc): introduce cache for sharing data across entry-points (#38840) ngcc creates typically two `ts.Program` instances for each entry-point, one for processing sources and another one for processing the typings. The creation of these programs is somewhat expensive, as it concerns module resolution and parsing of source files. This commit implements several layers of caching to optimize the creation of programs: 1. A shared module resolution cache across all entry-points within a single invocation of ngcc. Both the sources and typings program benefit from this cache. 2. Sharing the parsed `ts.SourceFile` for a single entry-point between the sources and typings program. 3. Sharing parsed `ts.SourceFile`s of TypeScript's default libraries across all entry-points within a single invocation. Some of these default library typings are large and therefore expensive to parse, so sharing the parsed source files across all entry-points offers a significant performance improvement. Using a bare CLI app created using `ng new` + `ng add @angular/material`, the above changes offer a 3-4x improvement in ngcc's processing time when running synchronously and ~2x improvement for asynchronous runs. PR Close #38840 15 September 2020, 18:23:18 UTC
84bd1a2 feat(dev-infra): include CI status check in the caretaker check (#38779) Add a CI status check in the ng-dev caretaker check command. PR Close #38779 15 September 2020, 15:45:06 UTC
ef13d8f fix(dev-infra): remove ANSI escape codes from log file outputs (#38792) Remove the ANSI codes from the log file outputs to make the ng-dev log files more readable. PR Close #38792 15 September 2020, 15:44:04 UTC
dc4f858 build: create temporary script for symbol extractor tests (#38819) Creates a temporary script to running all symbol extractor tests. PR Close #38819 14 September 2020, 23:54:45 UTC
2bdfb14 build: add tag to symbol-extractor tests (#38819) Add a tag to symbol-extractor tests to allow for bazel querying. PR Close #38819 14 September 2020, 23:54:42 UTC
26deef2 feat(dev-infra): allow local ng-dev configuration to error on invalid commit messages (#38784) As part of the commit message conformance check, local commit message checks are made to be warnings rather than failures. An additional local option is also in place to allow for the commit message validation failures to be considered errors instead. PR Close #38784 14 September 2020, 21:34:55 UTC
f52a494 docs(elements): convert the `ng add` command to code-example (#38834) the command was hardly visible currently changing it to shell for visibility PR Close #38834 14 September 2020, 21:31:10 UTC
ebede67 perf(compiler-cli): optimize computation of type-check scope information (#38843) When type-checking a component, the declaring NgModule scope is used to create a directive matcher that contains flattened directive metadata, i.e. the metadata of a directive and its base classes. This computation is done for all components, whereas the type-check scope is constant per NgModule. Additionally, the flattening of metadata is constant per directive instance so doesn't necessarily have to be recomputed for each component. This commit introduces a `TypeCheckScopes` class that is responsible for flattening directives and computing the scope per NgModule. It caches the computed results as appropriate to avoid repeated computation. PR Close #38843 14 September 2020, 20:07:08 UTC
5658405 perf(compiler-cli): only emit directive/pipe references that are used (#38843) For the compilation of a component, the compiler has to prepare some information about the directives and pipes that are used in the template. This information includes an expression for directives/pipes, for usage within the compilation output. For large NgModule compilation scopes this has shown to introduce a performance hotspot, as the generation of expressions is quite expensive. This commit reduces the performance overhead by only generating expressions for the directives/pipes that are actually used within the template, significantly cutting down on the compiler's resolve phase. PR Close #38843 14 September 2020, 20:07:03 UTC
c62d1cb refactor(dev-infra): do not validate config file multiple times (#38808) Currently we validate the configuration file on each `getConfig` invocation. We can only validate once since the configuration is cached. Also while being at it, renames the cache variables to lower-case as those do not represent constants (which are convention-wise upper case). PR Close #38808 14 September 2020, 15:34:19 UTC
aa43cbf fix(dev-infra): correct build setup for dev-infra (#38815) Correct's the missing dependencies and incorrect build dependencies for the dev-infra bazel targets. PR Close #38815 11 September 2020, 20:59:35 UTC
b05d79d build(router): update symbols for routing app (#38817) This commit updates the golden symbol files for the routing app. PR Close #38817 11 September 2020, 20:20:39 UTC
04c2bb9 build: create sample router app (#38714) This commit creates a sample router test application to introduce the symbol tests. It serves as a guard to ensure that any future work on the router package does not unintentionally increase the payload size. PR Close #38714 11 September 2020, 19:10:49 UTC
ec2dbe7 fix(compiler): detect pipes in ICUs in template binder (#38810) Recent work on compiler internals in #38539 led to an unexpected failure, where a pipe used exclusively inside of an ICU would no longer be emitted into the compilation output. This caused runtime errors due to missing pipes. The issue occurred because the change in #38539 would determine the set of used pipes up-front, independent from the template compilation using the `R3TargetBinder`. However, `R3TargetBinder` did not consider expressions within ICUs, so any pipe usages within those expressions would not be detected. This fix unblocks #38539 and also concerns upcoming linker work, given that prelink compilations would not go through full template compilation but only `R3TargetBinder`. PR Close #38810 11 September 2020, 19:07:43 UTC
8096c63 docs: clarify what fixes are merged to LTS versions (#38788) PR Close #38788 11 September 2020, 15:45:46 UTC
6ff9e6e refactor(dev-infra): add default params to runBenchmark (#38748) * Use '' as the default for 'url' * Use [] as the default for 'params' * Use true as the default for 'ignoreBrowserSynchronization' PR Close #38748 11 September 2020, 15:44:38 UTC
31d0ee4 docs: Move Displaying data topic and ToH tutorial (#38774) Move the "Displaying data topic" into the Tutorials section. Move the ToH tutorial to the top of the tutorials section. PR Close #38774 10 September 2020, 21:32:28 UTC
a47383d fix(localize): ensure that `formatOptions` is optional (#38787) Some lower level APIs are used by CLI, and requiring the `formatOpions` argument at that level is a breaking change. This commit makes it optional at every level to avoid the breaking change. PR Close #38787 10 September 2020, 17:55:08 UTC
9078187 docs: add note about only one label target being allowed to be applied to a PR (#38793) To clarify the use of GitHub labels for targetting PRs, a not about only being allowed to apply one label is added. PR Close #38793 10 September 2020, 16:41:06 UTC
dcb473d docs: update docs to reflect new PR targeting methods for release trains (#38401) (#38793) As part of the migration to a common strategy/method for branching and releasing across the main angular repositories, updates need to be made to the documentation. These changes reflect the updates made and is based on the following document which describes the merging label expectations: https://docs.google.com/document/d/197kVillDwx-RZtSVOBtPb4BBIAw0E9RT3q3v6DZkykU PR Close #38401 PR Close #38793 10 September 2020, 16:41:00 UTC
edb7f90 fix(core): clear the `RefreshTransplantedView` when detached (#38768) The `RefreshTransplantedView` flag is used to indicate that the view or one of its children is transplanted and dirty, so it should still be refreshed as part of change detection. This flag is set on the transplanted view itself as well setting a counter on as its parents. When a transplanted view is detached and still has this flag, it means it got detached before it was refreshed. This can happen for "backwards references" or transplanted views that are inserted at a location that was already checked. In this case, we should decrement the parent counters _and_ clear the flag on the detached view so it's not seen as "transplanted" anymore (it is detached and has no parent counters to adjust). fixes #38619 PR Close #38768 10 September 2020, 16:11:41 UTC
9c51ba3 fix(router): Ensure routes are processed in priority order and only if needed (#38780) There is a slight difference between `map`...`concatAll` and `concatMap` in that the latter (`concatMap`) will ensure that the computations are executed in-order and only if needed while the former may execute the `map` body of all items if they do not emit immediately. That is, if the stream is `from([a, b, c]).pipe(map(v => of(v).pipe(delay(1))), concatAll(), first())` the `map` body will execute for all of `a`, `b`, and `c`. However, the following will only execute the `concatMap` body for `a` `from([a, b, c]).pipe(concatMap(v => of(v).pipe(delay(1))), first())` See https://stackblitz.com/edit/rxjs-cvwxyx fixes #38691 PR Close #38780 10 September 2020, 15:54:39 UTC
d8714d0 refactor(core): _reset() remove nextRecord (#38752) The nextRecord is not neccessary, so remove it and use record._nextMoved to iterate PR Close #38752 10 September 2020, 15:52:54 UTC
5de2ac3 fix(upgrade): add try/catch when downgrading injectables (#38671) This commit improves the error thrown by the downgrade module with a more descriptive message on why the downgrade is failing. Closes #37579 PR Close #38671 10 September 2020, 15:50:18 UTC
7669bd8 feat(dev-infra): Allow local user ng-dev configuration to disable commit message wizard (#38701) As not all users, particularly contributors consistently contributing with a deep understanding of our commit message guidelines, will not want to rely on the commit message wizard, we allow a user to opt out of using this wizard during commit message creation. PR Close #38701 09 September 2020, 23:31:17 UTC
18d911d feat(dev-infra): Add support for local user ng-dev configuration (#38701) Create a utility for loading a local user configuration object to describe local configuration values, such as skipping the commit message wizard. PR Close #38701 09 September 2020, 23:31:17 UTC
38ff66d docs: put docs style guide back in left nav (#38683) PR Close #38683 09 September 2020, 23:22:58 UTC
5672aba refactor(dev-infra): update commit message validation to return validation result (#38703) Previously, the validateCommitMessage function ran validation and logged the results. The validateCommitMessage function now returns an object containing the validation results and the cli action functions are instead responsible for logging the results. This is being done as a prefactor for a change which allows for commit message hook validation to be either a blocking error or a warning. PR Close #38703 09 September 2020, 23:22:36 UTC
5567bdc test(language-service): [ivy] remove all markers from test (#38777) In the test project there are no longer reference markers and location markers, so there's no need to "pre-process" the source files to remove them. This will make the Ivy tests cleaner and faster. PR Close #38777 09 September 2020, 23:21:56 UTC
1c156eb release: cut the v10.1.1 release 09 September 2020, 20:12:30 UTC
3965484 Revert "perf(compiler-cli): only emit directive/pipe references that are used (#38749)" (#38767) This reverts commit 775c30577131cacaa3c1c3c1e7e02a233acf29a8. internal failure: https://test.corp.google.com/ui#id=OCL:329948619:BASE:329967516:1599160428139:d63165ae PR Close #38767 09 September 2020, 19:24:08 UTC
c541610 Revert "perf(compiler-cli): optimize computation of type-check scope information (#38749)" (#38767) This reverts commit e156e29eddcc85b2197f3b052ed76dd132671401. internal failure: https://test.corp.google.com/ui#id=OCL:329948619:BASE:329967516:1599160428139:d63165ae PR Close #38767 09 September 2020, 19:24:08 UTC
f1b355b docs: Restructure table of contents to provide a more streamlined experience (#38763) This PR is to make the `10.1.x` branch navigation the same as `master`. PR Close #38763 09 September 2020, 17:46:09 UTC
e40ffb9 docs: add Andrew Grekov to GDE resources (#36690) This commit adds Andrew Grekov to the GDE resources page and describes his work as a software engineer using angular and .NET. PR Close #36690 09 September 2020, 16:44:48 UTC
20564f9 docs: add Sam Vloeberghs to GDE list (#38761) PR Close #38761 09 September 2020, 16:43:37 UTC
b1398d1 docs(docs-infra): add The Deep Dive podcast, update Angular inDepth URL (#37621) Add the new podcast called The Deep Dive to the list of Podcast resources. Also replace the name and URL for Angular inDepth as the old URL is deprecated. PR Close #37621 09 September 2020, 16:11:11 UTC
7e9134a docs(router): fixed PreloadAllModules comment typo (#38758) PR Close #38758 09 September 2020, 16:07:50 UTC
0a55058 docs: mark the `entryComponents` array as deprecated (#38616) The `entryComponents` array is now deprecated (per https://angular.io/api/core/NgModule#entryComponents and https://angular.io/guide/deprecations#entryComponents). PR Close #38616 09 September 2020, 16:07:19 UTC
bb1122d docs: update v9 support status to LTS (#38744) PR Close #38744 09 September 2020, 16:06:56 UTC
2ea49c7 fix(dev-infra): set build commit message type to allow an optional scope (#38745) Allow, optionally, a scope to be used with the build type commit message. PR Close #38745 09 September 2020, 16:06:33 UTC
83d6997 docs: Fix component decorator closing brackets (#38754) PR Close #38754 09 September 2020, 16:06:10 UTC
62de213 docs: add missing space (#38759) This commit adds a missing space after the comma in listing the rxjs operators section. PR Close #38759 09 September 2020, 16:05:47 UTC
e156e29 perf(compiler-cli): optimize computation of type-check scope information (#38749) When type-checking a component, the declaring NgModule scope is used to create a directive matcher that contains flattened directive metadata, i.e. the metadata of a directive and its base classes. This computation is done for all components, whereas the type-check scope is constant per NgModule. Additionally, the flattening of metadata is constant per directive instance so doesn't necessarily have to be recomputed for each component. This commit introduces a `TypeCheckScopes` class that is responsible for flattening directives and computing the scope per NgModule. It caches the computed results as appropriate to avoid repeated computation. PR Close #38749 08 September 2020, 22:35:32 UTC
775c305 perf(compiler-cli): only emit directive/pipe references that are used (#38749) For the compilation of a component, the compiler has to prepare some information about the directives and pipes that are used in the template. This information includes an expression for directives/pipes, for usage within the compilation output. For large NgModule compilation scopes this has shown to introduce a performance hotspot, as the generation of expressions is quite expensive. This commit reduces the performance overhead by only generating expressions for the directives/pipes that are actually used within the template, significantly cutting down on the compiler's resolve phase. PR Close #38749 08 September 2020, 22:35:32 UTC
190dca0 fix(localize): enable whitespace preservation marker in XLIFF files (#38737) Whitespace can be relevant in extracted XLIFF translation files. Some i18n tools - e.g. CAT tool (OmegaT) - will reformat the file to collapse whitespace if there is no indication to tell it not to. This commit adds the ability to specify "format options" that are passed to the translation file serializer. The XLIFF 1.2 and 2.0 seralizers have been updated to accept `{"xml:space":"preserve"}` format option which will by added to the `<file>` element in the serialized translation file during extraction. Fixes #38679 PR Close #38737 08 September 2020, 21:24:52 UTC
309709d fix(router): If users are using the Alt key when clicking the router links, prioritize browser’s default behavior (#38375) In most browsers, clicking links with the Alt key has a special behavior, for example, Chrome downloads the target resource. As with other modifier keys, the router should stop the original navigation to avoid preventing the browser’s default behavior. When users click a link while holding the Alt key together, the browsers behave as follows. Windows 10: | Browser | Behavior | |:-----------|:--------------------------------------------| | Chrome 84 | Download the target resource | | Firefox 79 | Prevent navigation and therefore do nothing | | Edge 84 | Download the target resource | | IE 11 | No impact | macOS Catalina: | Browser | Behavior | |:-----------|:--------------------------------------------| | Chrome 84 | Download the target resource | | Firefox 79 | Prevent navigation and therefore do nothing | | Safari 13 | Download the target resource | PR Close #38375 08 September 2020, 21:07:11 UTC
028ef30 docs: Describe a scenario in which ngOnChanges is not called before ngOnInit. (#38625) Closes #38613 PR Close #38625 08 September 2020, 21:06:48 UTC
56d5ff2 fix(compiler-cli): ensure that a declaration is available in type-to-value conversion (#38684) The type-to-value conversion could previously crash if a symbol was resolved that does not have any declarations, e.g. because it's imported from a missing module. This would typically result in a semantic TypeScript diagnostic and halt further compilation, therefore not reaching the type-to-value conversion logic. In Bazel however, it turns out that Angular semantic diagnostics are requested even if there are semantic TypeScript errors in the program, so it would then reach the type-to-value conversation and crash. This commit fixes the unsafe access and adds a test that ignores the TypeScript semantic error, effectively replicating the situation as experienced under Bazel. Fixes #38670 PR Close #38684 08 September 2020, 21:06:25 UTC
b4eb016 fix(compiler-cli): compute source-mappings for localized strings (#38747) Previously, localized strings had very limited or incorrect source-mapping information available. Now the i18n AST nodes and related output AST nodes include source-span information about message-parts and placeholders - including closing tag placeholders. This information is then used when generating the final localized string ASTs to ensure that the correct source-mapping is rendered. See #38588 (comment) PR Close #38747 08 September 2020, 21:00:35 UTC
6b0dba4 refactor(compiler): move the MessagePiece classes into output_ast.ts (#38747) The `MessagePiece` and derived classes, `LiteralPiece` and `PlaceholderPiece` need to be referenced in the `LocalizedString` output AST class, so that we can render the source-spans of each piece. PR Close #38747 08 September 2020, 21:00:35 UTC
cfd4c0b refactor(compiler): track the closing source-span of TagPlaceholders (#38747) The `TagPlaceholder` can contain children, in which case there are two source spans of interest: the opening tag and the closing tag. This commit now allows the closing tag source-span to be tracked, so that it can be used later in source-mapping. PR Close #38747 08 September 2020, 21:00:34 UTC
3876202 refactor(compiler): capture interpolation source-spans in expression parser (#38747) The expression parser will split the expression up at the interpolation markers into expressions and static strings. This commit also captures the positions of these strings in the expression to be used in source-mapping later. PR Close #38747 08 September 2020, 21:00:34 UTC
a1c34c6 fix(compiler): correct confusion between field and property names (#38685) The `R3TargetBinder` accepts an interface for directive metadata which declares types for `input` and `output` objects. These types convey the mapping between the property names for an input or output and the corresponding property name on the component class. Due to `R3TargetBinder`'s requirements, this mapping was specified with property names as keys and field names as values. However, because of duck typing, this interface was accidentally satisifed by the opposite mapping, of field names to property names, that was produced in other parts of the compiler. This form more naturally represents the data model for inputs. Rather than accept the field -> property mapping and invert it, this commit introduces a new abstraction for such mappings which is bidirectional, eliminating the ambiguous plain object type. This mapping uses new, unambiguous terminology ("class property name" and "binding property name") and can be used to satisfy both the needs of the binder as well as those of the template type-checker (field -> property). A new test ensures that the input/output metadata produced by the compiler during analysis is directly compatible with the binder via this unambiguous new interface. PR Close #38685 08 September 2020, 18:43:03 UTC
b084bff perf(core): use `ngDevMode` to tree-shake error messages (#38612) This commit adds `ngDevMode` guard to throw some errors only in dev mode (similar to how things work in other parts of Ivy runtime code). The `ngDevMode` flag helps to tree-shake these error messages from production builds (in dev mode everything will work as it works right now) to decrease production bundle size. PR Close #38612 08 September 2020, 18:41:44 UTC
6a28675 fix(ngcc): use aliased exported types correctly (#38666) If a type has been renamed when it was exported, we need to reference the external public alias name rather than the internal original name for the type. Otherwise we will try to import the type by its internal name, which is not publicly accessible. Fixes #38238 PR Close #38666 08 September 2020, 18:41:21 UTC
4de8dc3 fix(localize): do not expose NodeJS typings in $localize runtime code (#38700) A recent change to `@angular/localize` brought in the `AbsoluteFsPath` type from the `@angular/compiler-cli`. But this brought along with it a reference to NodeJS typings - specifically the `FileSystem` interface refers to the `Buffer` type from NodeJS. This affects compilation of `@angular/localize` code that will be run in the browser - for example projects that reference `loadTranslations()`. The compilation breaks if the NodeJS typings are not included in the build. Clearly it is not desirable to have these typings included when the project is not targeting NodeJS. This commit replaces references to the NodeJS `Buffer` type with `Uint8Array`, which is available across all platforms and is actually the super-class of `Buffer`. Fixes #38692 PR Close #38700 08 September 2020, 18:40:58 UTC
ab4f953 fix(localize): render location in XLIFF 2 even if there is no metadata (#38713) Previously, the location of a translation message, in XLIFF 2, was only rendered if there were also notes for meaning or description. Now the location will be rendered even if the other metadata is not provided. Fixes #38705 PR Close #38713 08 September 2020, 18:40:35 UTC
ee432aa refactor(core): remove deprecated `ɵɵselect` instruction (#38733) This instruction was deprecated in 664e0015d4de720216c52b13b808f9ba41b7da38 and is no longer referenced in any meaningful way, so it can be removed. PR Close #38733 08 September 2020, 18:40:12 UTC
5863537 build: upgrade all preview-server JS dependencies to latest versions (#38736) This commit upgrades all dependencies in `aio/aio-builds-setup/scripts-js/` to latest versions and also includes all necessary code changes to ensure the tests are passing with the new dependency versions. In particular: - We ensure `nock`'s `Scope#done()` is not called before receiving a response to account for a breaking change introduced in nock/nock#1960. - The use of `nock`'s `Scope#log()` method was removed, because the method is no longer available since nock/nock#1966. See https://github.com/nock/nock#debugging for more info on debugging failed matches. See also https://github.com/nock/nock/blob/e23ba31b137ec43ac83e47395b4992d62832bde1/migration_guides/migrating_to_13.md for more info on migrating from `nock` v12 to v13. PR Close #38736 08 September 2020, 17:07:26 UTC
fcd2eb2 fix(dev-infra): change logging of commit message restoration to debug (#38704) Use debug level of logging for messages in commit message restoration. PR Close #38704 08 September 2020, 17:07:03 UTC
251a28c docs: remove duplicate trans-unit element closing tag (#38715) PR Close #38715 08 September 2020, 17:06:03 UTC
back to top