25055 Commits

Author SHA1 Message Date
Pawel Kozlowski dacac7eb62 release: cut the v14.1.3 release 14.1.3 2022-08-17 16:55:45 +02:00
Kristiyan Kostadinov 0583227708 fix(compiler): infinite loop in parser assignment expression with invalid left-hand expression (#47151)
In #39004 some logic was introduced that tries to recover invalid expressions by treating the `=` token as a recovery point. It works by skipping ahead to the next recovery point inside the `skip` method which is called whenever an error is reported. This can lead to an infinite loop inside the `parseChain` method which assumes that reporting an error would've skipped over the token, but that won't happen since the `=` token is a recovery point. These changes resolve the infinite loop by breaking the loop if `error` didn't skip to a different token after the error was reported.

Fixes #47131.

PR Close #47151
2022-08-17 07:33:32 +00:00
George Kalpakas 3d9455ee8b build(docs-infra): upgrade cli command docs sources to 07471d230 (#47149)
Updating [angular#14.1.x](https://github.com/angular/angular/tree/14.1.x) from
[cli-builds#14.1.x](https://github.com/angular/cli-builds/tree/14.1.x).

##
Relevant changes in
[commit range](https://github.com/angular/cli-builds/compare/a764b37fa...07471d230):

**Modified**
- help/cache.json

PR Close #47149
2022-08-15 15:18:00 +00:00
Roman Matusevich 970e68ae38 docs: remove duplicated styles (#47143)
PR Close #47143
2022-08-12 18:18:20 +00:00
Roman Matusevich 5ffc882864 docs: fix code samples formatting in tutorial (#47144)
PR Close #47144
2022-08-12 18:17:27 +00:00
Andrew Scott a5ca049fd9 refactor(router): Provide easily patchable file for assigning relativeLinkResolution (#47136)
For context on the migration plan, see b/241955063

PR Close #47136
2022-08-12 16:11:34 +00:00
Bob Watson bb465e1789 docs: set titles to sentence case (#47083)
* update overview and reviewing topics to accommodate new ToC
* incorporate edits from peer reviews

PR Close #47083
2022-08-12 18:04:26 +02:00
Andrew Scott 5547ce0aaa refactor(router): Update error message when Router is provided twice (#47130)
The current error message is absolute in that it thinks there is only
one possible way to provide Router twice. In fact, you can get a new
instance of the Router in several ways so the error message should
indicate the exact failure case with a _potential_ cause.

Based on findings in thread https://github.com/angular/angular/commit/0cbbd6aeecda8ea994f1086727e580b813a53d79#commitcomment-80900192

PR Close #47130
2022-08-12 13:27:50 +00:00
Bob Watson 09d57530db docs: clarify use of unsubscribe with HttpClient (#47127)
fix: #46542

PR Close #47127
2022-08-12 09:58:05 +00:00
AlirezaEbrahimkhani 063035f86d docs: fix embedded view description issue (#46957)
createEmbeddedView method instantiates an embedded view based on this template and take your templateRef as argument and would render the passed templateRef in your ViewContainerRef.

resolves angular#46955

PR Close #46957
2022-08-11 18:07:39 +00:00
Kalbarczyk 0a99130f85 docs: add NG Poland 2022 and JS Poland 2022 to events (#47128)
PR Close #47128
2022-08-11 17:03:07 +00:00
Alma Eyre 6a94157d6f docs: Moving a div down in tutorial toh-pt6.md (#47095)
PR Close #47095
2022-08-11 16:09:51 +00:00
Sonu Kapoor bb40a08164 docs: rename duplicate header (#47110)
PR Close #47110
2022-08-11 16:08:38 +00:00
Leosvel Pérez Espinosa c365cfab03 docs: remove duplicated sentence (#47126)
PR Close #47126
2022-08-11 16:04:16 +00:00
Dylan Hunn b31f5dd2f0 release: cut the v14.1.2 release 14.1.2 2022-08-10 11:07:49 -07:00
Andrew Scott 2548712aba build: add atscott to unavailable users (#47102)
PR Close #47102
2022-08-10 10:45:38 -07:00
4javier f4fa4afd04 docs: clarify providers' injection in lazy loaded modules (#47094)
Addresses https://github.com/angular/angular/issues/47059
I try to keep the edit as concise as possible because adding any further
explanation would bring to much deeper info compared to the topic of the
page

Removed some convoluted info and replaced with a link to a page that
should focus on the specific aspect of the matter.
Conditional is obliged because IMHO that page should have a dedicated
paragraph explaining various ways of populating different injectors with
providers, and maybe integrating the interesting parts from the recent
created page about standalone app.
PR Close #47094
2022-08-10 10:45:04 -07:00
Andrew Scott 439d77e852 fix(router): Fix route recognition behavior with some versions of rxjs (#47098) (#47112)
Some versions of rxjs cause the algorithm used in the Router to not recognize Route configs correctly.
This commit updates the algorithm to be compatible in the same way as other code locations internally.

Context:
https://github.com/angular/angular/commit/1160b8194f78141b40d1d4885ec182d033ff2659

fixes #47089

Note: This does not have a test because I was unable to identify the
version of rxjs that would cause a failure here.

PR Close #47098

PR Close #47112
2022-08-10 10:43:50 -07:00
Angular Robot 036f740f77 build: update github/codeql-action action to v2.1.18 (#47015)
See associated pull request for more information.

PR Close #47015
2022-08-09 10:56:00 -07:00
AntonioCardenas e10aa8858f docs: add antoniocardenas to GDE resources (#47033)
PR Close #47033
2022-08-09 10:02:12 -07:00
Vovch 38d23af419 docs: change "zone" to "ngZone" in an example (#47079)
Change requesting "this.zone" to "this.ngZone" in the Plotly example, as it corresponds to the name declared in the constructor.
PR Close #47079
2022-08-09 10:01:27 -07:00
Angular Robot 923a7446a2 build: update eslint dependencies to v5.33.0 (#47087)
See associated pull request for more information.

PR Close #47087
2022-08-09 10:00:11 -07:00
Bob Watson 874d78b502 docs: add more documentation about lint messages (#47019)
Adds suggestions for how to resolve the most common messages produced by the documentation linter.

Adds links to the Proselint and other style tests to the new documentation.

Updates pullapprove and navigation.

PR Close #47019
2022-08-08 11:34:56 -07:00
onrails 8d18969714 docs: updated reference link to NativeScript/Angular documentation (#47063)
PR Close #47063
2022-08-08 11:34:21 -07:00
Mladen Jakovljević 2106b74853 refactor: improve disabled attribute warning (#47041)
Users using the "disabled" property binding on reactive form controls would want to know how to dynamically update the disabled state of a form control when they get a console warning.

PR Close #47041
2022-08-08 11:33:53 -07:00
Eduardo Speroni 5ff715c549 fix(core): check if transplanted views are attached to change detector (#46974)
Prevents change detection on views transplanted in OnPush components that have been detached from change detection.

PR Close #46974
2022-08-08 11:33:29 -07:00
Edward 30c9e80a30 docs: fix dependecy injection documentation page typos (#47057)
PR Close #47057
2022-08-08 11:33:05 -07:00
Bruno Barbosa 0392feb135 fix(docs-infra): fix nav css on tutorial tour of heroes (#47064)
Fix the navigation button to work properly by the css style applied when the button is active, on tutorial Tour of Heroes.

PR Close #47064
2022-08-08 11:32:40 -07:00
Kristiyan Kostadinov 6d215d3124 refactor(core): remove unused module tracking (#47066)
We used to track all modules in a top-level constant called `autoRegisterModuleById` which was used by `getRegisteredNgModuleType`. As of #45024 the constant isn't being used anymore so we can remove it.

PR Close #47066
2022-08-08 11:32:17 -07:00
Roman Matusevich e46972ac4b docs: fix text formatting for paragraph in Hierarchical injectors (#47067)
Paragraph of text is not wrapped into `p` tag due to missing empty line after the `div` block. The fix is just add an empty line.

PR Close #47067
2022-08-08 11:31:44 -07:00
Pawel Kozlowski 2e42bb9c62 docs: update link to the TypeScript handbook (#47075)
Closes #47070
PR Close #47075
2022-08-08 11:31:19 -07:00
Paul Gschwendtner d14235cfb1 ci: invalidate circleci caches to prune nested node_modules (#46707)
Yarn 1.x. is known to not prune nested unused node modules. This throws
off Bazel when the dependency tree changes but there are leftover unused
nested node module folders. This causes CI failures currently after the
dependency tree updates.

Invalidating the cache fixes this issue. Long-term a switch to Yarn
2.x+, pnpm will fix this.

PR Close #46707
2022-08-08 09:23:56 -07:00
Angular Robot befd650a78 build: update all non-major dependencies (#46707)
See associated pull request for more information.

PR Close #46707
2022-08-08 09:23:56 -07:00
Jan Melcher fd2abebf91 docs: fix link in dependency injection guide (#47055)
PR Close #47055
2022-08-08 09:23:06 -07:00
ileil 387f4a79f8 docs: update dependency injection content (#44466)
Refactored the DI section to improve doc quality, reduce cognitive load and drive consistency.

- Added an overview with prerequisites and doc cards that point to rest of the DI content
- Added introduction topic with topic purpose, value proposition and "fail fast"
- Broke apart complex concepts into simpler tasks
- Unified tone and language for each topic
- Added new content based on SME feedback
- Deleted obsolete content

PR Close #44466
2022-08-05 10:06:14 -07:00
Angular Robot 8f32c09872 build: update io_bazel_rules_sass digest to 697e5a0 (#47046)
See associated pull request for more information.

PR Close #47046
2022-08-05 09:57:45 -07:00
Paul Gschwendtner 04b3497db1 build: update ngsw-config.json after redirect changes (#47048)
Looks like the `ngsw-config.json` file needs to be updated after a new
redirect being added in: https://github.com/angular/angular/pull/46820.

PR Close #47048
2022-08-05 09:56:57 -07:00
Paul Gschwendtner d0e3ad5300 refactor(docs-infra): update safevalues and account for API changes (#47048)
Updates `safevalues` to unblock
https://github.com/angular/angular/pull/46707. As part of this commit
the necessary refactorings due to API changes are also made.

PR Close #47048
2022-08-05 09:56:57 -07:00
Andrew Scott c7fed38cf0 refactor(router): Cherry-pick Router services to be providedIn: 'root' (#47052)
Recent refactoring in the Router made services available via
`providedIn: 'root'`. However, some of these changes were not merged to
the patch branch. This commit updates the remaining services needed to
create the `Router` without `RouterModule` and adds a test to ensure it
works.

PR Close #47052
2022-08-05 09:36:11 -07:00
Angular Robot 1d39ab6e6b build: update io_bazel_rules_sass digest to 70ffe01 (#47023)
See associated pull request for more information.

PR Close #47023
2022-08-04 13:08:42 -07:00
ashide2729 fce4ea1d8d docs: add yarn build fail workaround on windows (#47037)
PR Close #47037
2022-08-04 13:08:19 -07:00
George Kalpakas 2a833e6eac ci: fix Renovate post-upgrade task command (#47040)
Since Renovate runs from the project directory, it cannot find the
`sync-deps` yarn script inside `aio/tools/examples/shared/`:
[example failure][1]

Update the post-upgrade task command to run inside that directory
instead of the project root.

[1]: https://github.com/angular/angular/pull/46707#issuecomment-1203335639

PR Close #47040
2022-08-04 13:07:56 -07:00
Bob Watson d0f4f1d601 docs: update Vale installation instructions (#47031)
This update includes:
* installation directions for the current version of the Vale VSCode extension (v. 0.15.0)
* a workaround for if the current version of the extension doesn't work.

PR Close #47031
2022-08-03 17:35:31 -07:00
Andrew Kushnir 3ee883e417 fix(docs-infra): do not require @ngModule tag on standalone types (#47024)
This commit updates docs extraction logic to avoid requiring the `@ngModule` tag on standalone types, since they don't have to be present in any NgModule.

PR Close #47024
2022-08-03 11:04:56 -07:00
Andrew Kushnir b868f1c94e release: cut the v14.1.1 release 14.1.1 2022-08-03 10:48:18 -07:00
Andrew Scott efb8e3e431 docs(core): Update inject error documentation (#47020)
The inject function is also available when using EnvironmentInjector.runInContext.

PR Close #47020
2022-08-02 18:06:55 -07:00
Angular Robot 8085fe34f1 build: update eslint dependencies to v5.32.0 (#47016)
See associated pull request for more information.

PR Close #47016
2022-08-02 11:59:42 -07:00
George Kalpakas 9edfe4ac97 build(docs-infra): ensure all boilerplate dependencies are in sync (#47009)
All docs examples share the same `node_modules/` (symlinked into each
example from `aio/tools/examples/shared/node_modules/`). However, each
example type has a different `package.json`, which comes from
`aio/tools/examples/shared/boilerplate/*`). In order to ensure that the
dependencies in each example's `package.json` are the same as the ones
in the symlinked `node_modules/` (i.e. the ones that CI tests are run
with), we have a script (`yarn run sync-deps`) that can sync
dependencies from `shared/package.json` into the boilerplate
`package.json` files.

Previously, this script had to be run manually, which was easy to
forget/not know about and resulted in the boilerplate dependencies
often being out-of-sync with the ones in `shared/package.json` (and by
extension, the ones that were actually installed in `node_modules/`).

This commit helps keep the boilerplate dependencies up-to-date in the
following ways:
- Adds the `sync-deps` script to the `postinstall` scripts.
  This ensures that dependencies remain in sync whenever someone
  manually updates dependencies in `shared/package.json`.
- Runs the `sync-deps` script as a Renovate post-upgrade task.
  This ensures that the depenencies remain in sync whenever Renovate
  updates dependencies in `shared/package.json`.
  For more info on configuring post-upgrade tasks in Renovate, see:
  - [postUpgradeTasks][1]
  - [allowedPostUpgradeCommands][2]
  - [allowPostUpgradeCommandTemplating][3]

NOTE:
For the Renovate change to take effect, the [global config][4] in
`angular/dev-infra` also needs to be updated. This will be done in a
separate PR.

[1]: https://docs.renovatebot.com/configuration-options/#postupgradetasks
[2]: https://docs.renovatebot.com/self-hosted-configuration/#allowedpostupgradecommands
[3]: https://docs.renovatebot.com/self-hosted-configuration/#allowpostupgradecommandtemplating
[4]: https://github.com/angular/dev-infra/blob/22d3067021130271afcfd02d063828c5bdd9c2d7/.github/ng-renovate/runner-config.js

PR Close #47009
2022-08-02 11:58:51 -07:00
Andrew Scott 79825d3f10 fix(router): Do not call preload method when not necessary (#47007)
In Angular 14, we introduced the `loadComponent` API for a `Route` to
allow lazy loading of a routed component in addition to the existing
`loadChildren` which allows lazy loading of child routes. As a result,
the `preload` method of the `PreloadingStrategy` needs to sometimes be
called even when there is a `canLoad` guard on the `Route`. `CanLoad`
guards block loading of child routes but _do not_ block loading of the
component.

This change updates the conditional checks in the internal preloader to
skip calling the `PreloadingStrategy.preload` when there is only a
`loadChildren` callback with a `canLoad` guard an no `loadComponent`.
In this case, the callback passed to the `preload` method is already
effectively a no-op so it's not necessary to call it at all.

resolves #47003

PR Close #47007
2022-08-02 09:38:28 -07:00
Paul Gschwendtner 4e9492cf6d build: update dev-infra packages and account for build-tooling split from ng-dev (#46976)
The dev-infra build tooling is now decoupled from `ng-dev`. This will
make it easier to update `ng-dev` without necessarily needing to upgrade
the whole build system, Bazel etc. This is useful when e.g. new release
tool features have been added and should also be ported to active LTS
branches.

PR Close #46976
2022-08-02 09:37:38 -07:00