21813 Commits

Author SHA1 Message Date
dario-piotrowicz c02e5e15b6 refactor(common): removed TODO no longer considered necessary (#43378)
The TODO comment suggesting to verify that the target element to
scroll to needs to be an anchor does not longer seems under consideration
so it can be removed

resolves #43348

PR Close #43378
2021-09-07 23:05:32 +00:00
Paul Gschwendtner 01d2f03d3d ci: avoid failures when yarn unlinks bazelisk in windows jobs (#43365)
Windows disallows removal of files which are currently being used.
i.e. have active handles. This currently can result in permission denied
failures on the Windows CI jobs where `yarn bazel` resolves to the local
bazelisk installation that can be unlinked by `yarn_install` repository
fetching as part of the Bazel invocation, resulting in errors like:

```
ERROR: An error occurred during the fetch of repository 'npm':
   yarn_install failed: $ node tools/yarn/check-yarn.js
...
[4/5] Linking dependencies...
info If you think this is a bug, please open a bug report with the information provided in "C:\\users\\circleci\\ng\\yarn-error.log".
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
 (warning " > tsickle@0.34.3" has incorrect peer dependency "typescript@~3.3.1".
error An unexpected error occurred: "EPERM: operation not permitted, unlink 'C:\\users\\circleci\\ng\\node_modules\\@bazel\\bazel-win32_x64\\bazel-0.27.0-windows-x86_64.exe'".
Process stalled
Active handles:
  - Socket
  - Socket
  - Socket
)
```

We workarund this in order to improve CI stability in case the node modules are
being invalidated by Bazel, or through Yarns integrity checking.

PR Close #43365
2021-09-07 21:29:58 +00:00
Paul Gschwendtner e5f9d2d046 build: check .ng-dev tool configuration in CI (#43365)
Checks the `.ng-dev` tool configuration in CI, compared
to doing it locally when the caretaker intends to perform
a merge and then realizes the config is broken.

PR Close #43365
2021-09-07 21:29:58 +00:00
Paul Gschwendtner 68a7cc12e4 build: update bazel setup to latest versions (#43365)
Updates the overall Bazel setup to their latest versions:

* rules_nodejs is updated to stable 4.0.0
* rules_sass is updated to the latest version containing a fix
  for the `@bazel/worker` bug we had a workaround for.
* dev-infra-private is updated to avoid duplicated dependencies.
  We should use a version that also relies on stable rules_nodejs v4.

Note: We are not set on how dependencies for the `bazel/` folder
of the dev-infra package are managed, but we removed `@types/`
packages from the transitive dependencies, so we now need to
manually include `@types/uuid` for building the benchmark driver
utilties. We need to revisit this in the future.

PR Close #43365
2021-09-07 21:29:58 +00:00
Charles Barnes 0bfb5b1f00 docs: remove Angular 9 from support table (#43350)
PR Close #43350
2021-09-07 21:29:32 +00:00
dario-piotrowicz 1bc1971d15 docs: fix app-hero-detaill typo (#43349)
PR Close #43349
2021-09-07 21:25:03 +00:00
George Kalpakas 4e11347a25 build: update feature request template to include core package (#43323)
Update the dropdown list to include core in the list of packages.
PR Close #43323
2021-09-07 21:24:15 +00:00
William Sedlacek 3b4f121caf docs(common): correct typos in jsdoc of http client (#43352)
This corrects four typos in the HttpClient JSDoc
capabilites => capabilities
reuested => requested
wuth => with
responmse => response
PR Close #43352
2021-09-07 18:45:16 +00:00
Ikko Ashimine d8f9e6131f refactor: fix typo in postinstall-patches.js (#43362)
refering -> referring
PR Close #43362
2021-09-07 18:44:47 +00:00
Enea Jahollari aa1782cee6 docs: enhance spacings in dynamic component loader section examples (#43241)
PR Close #43241
2021-09-02 16:45:10 +00:00
Enea Jahollari 4e4a198b3f docs: enhance spacings in content projection section examples (#43241)
PR Close #43241
2021-09-02 16:45:10 +00:00
Enea Jahollari 5af952491a docs: enhance spacings in inputs outputs section examples (#43241)
PR Close #43241
2021-09-02 16:45:10 +00:00
Enea Jahollari d7711d0510 docs: enhance spacings in component interaction section examples (#43241)
PR Close #43241
2021-09-02 16:45:10 +00:00
Enea Jahollari f5d0c889ab docs: enhance spacings in component lifecycle section examples (#43241)
PR Close #43241
2021-09-02 16:45:09 +00:00
Enea Jahollari dc46cc4b37 docs: enhance spacings in component overview section examples (#43241)
PR Close #43241
2021-09-02 16:45:09 +00:00
Enea Jahollari 39c50b577e docs: enhance spacings in try it section examples (#43241)
PR Close #43241
2021-09-02 16:45:09 +00:00
Enea Jahollari 8e1c309e52 docs: enhance what is angular section spacing (#43241)
PR Close #43241
2021-09-02 16:45:09 +00:00
Pete Bacon Darwin a6e22c4b8e build(docs-infra): update dgeni-packages to improve checkLinks messages (#43317)
This update should make the list of files with broken links more readable.

Fixes #43214

PR Close #43317
2021-09-02 16:44:47 +00:00
Alan Agius a0bd6e90f9 fix(router): add more context to Unhandled Navigation Error (#43291)
Previously, the error message was not added to `Unhandled Navigation Error`

Before
```
main.js:1 Unhandled Navigation Errors:
```

After
```
main.js:1 Unhandled Navigation Errors: SecurityError: Failed to execute 'replaceState' on 'History': A history state object with URL 'http://localhost:4200/' cannot be created in a document with origin 'http://127.0.0.1:8080' and URL 'http://127.0.0.1:8080/'.
```

PR Close #43291
2021-09-01 21:15:00 +00:00
Jessica Janiuk caecd1889b release: cut the v12.2.4 release (#43308) 12.2.4 2021-09-01 13:30:13 -05:00
George Kalpakas d8f637ab43 docs: add step to declare ProductAlertsComponent in tutorial (#43229)
The getting-started tutorial at angular.io/start instructs users to
generate a `ProductAlertsComponent` using the "Angular generator"
feature in [StackBlitz](https://stackblitz.com/). However, unlike the
Angular CLI, generating a component in StackBlitz does not automatically
declare it in `AppModule`, which is a requirement for the component to
be used in the application. This resulted in a compile error when
following the tutorial instructions.

This commit fixes this by adding a step to manually import and declare
the newly generated component in `app.module.ts`.

Fixes #43020
Closes #43212

PR Close #43229
2021-08-30 13:37:46 -07:00
Joey Perrott 46bd8f2495 ci: update pullapprove config to reflect kyliau's departure (#43230)
Update pullapprove configuration to remove kyliau from groups.

PR Close #43230
2021-08-30 08:23:41 -07:00
Joey Perrott d84a4eb90f docs: remove recent departures from contributors page (#43230)
PR Close #43230
2021-08-30 08:23:40 -07:00
Daniel Trevino 692e8ab21e test(compiler-cli): add tests for NullishCoalescingNotNullableCheck (#43232)
Add tests to make sure the nullish coalescing check is generating the
correct diagnostics.

Refs #42966

PR Close #43232
2021-08-26 16:36:33 -07:00
Daniel Trevino 5d64d17a52 refactor(compiler-cli): add NullishCoalescingNotNullableCheck (#43232)
Add a template check that returns diagnostics if the left side of a
nullish coalescing operation is not nullable.

Refs #42966

PR Close #43232
2021-08-26 16:36:33 -07:00
Daniel Trevino 9c6399926a refactor(compiler-cli): use TemplateCheckWithVisitor in InvalidBananaInBoxCheck (#43232)
Modify the existing template check to use the new abstract class. This
makes template checks easier to read and understand.

Refs #42966

PR Close #43232
2021-08-26 16:36:32 -07:00
Daniel Trevino 75fc846745 refactor(compiler-cli): add abstract TemplateCheckWithVisitor class (#43232)
Add an abstract class that has a default implementation of the run
function and visits all nodes. Authors of template checks can extend
this class and override the `visitNode` method to return diagnostics.

Refs #42966

PR Close #43232
2021-08-26 16:36:32 -07:00
Daniel Trevino debe517d4f refactor(compiler-cli): move component out of TemplateContext (#43232)
Move `component` out of the `TemplateContext` so the context can be
reused for multiple components.

Refs #42966

PR Close #43232
2021-08-26 16:36:32 -07:00
Daniel Trevino e29f1d9cf8 refactor(compiler-cli): change checks folder structure (#43232)
Change template checks into `extended/checks` instead of
`extended/src/template_checks`.

Refs #42966

PR Close #43232
2021-08-26 16:36:32 -07:00
Daniel Trevino 553eb2cc9f refactor(compiler-cli): remove whitespace (#43232)
Remove extra whitespace introduced in a previous PR.

PR Close #43232
2021-08-26 16:36:32 -07:00
Joey Perrott 30d959a48a build: update issue template to include core package (#43272)
Update the dropdown list to include core in the list of packages.

PR Close #43272
2021-08-26 19:43:14 +00:00
Andrew Scott fdcb420bd7 docs(router): Fix incorrect name for url match options (#43268)
fixes #43123

PR Close #43268
2021-08-26 10:07:24 -07:00
Kristiyan Kostadinov 524b4d5a1f refactor(forms): make error messages easier to tree shake (#43223)
Currently the error message functions are defined as static methods on a class which means that as soon as one of them is used somewhere, all of them have to be retained. This isn't a problem at the moment, because all of them are behind `ngDevMode` checks, but it's error prone and it's easy to fix.

These changes move them out into functions so that they can be imported individually. It also has the advantage of allowing Webpack to minify the function names.

PR Close #43223
2021-08-26 10:05:36 -07:00
segunb fb64f711f8 docs: Close #View tag to avoid confusion (#43256)
PR Close #43256
2021-08-26 09:44:08 -07:00
nickreid e7e78e6709 refactor(zone.js): Rename class ZoneDelegate to _ZoneDelegate to differentiate it from the ZoneDelgate interface (#43019)
The current naming causes tsickle to emit `/** @implements {ZoneDelegate} */ class ZoneDelegate ...`, which is a cyclic definition error in Closure Compiler. Additionally, the name shadowing is also confusing to humans.

PR Close angular#43019

PR Close #43019
2021-08-25 15:12:01 -07:00
nickreid 8233906be2 fix(compiler-cli): Emit type annotations for synthesized decorator fields (#43021)
Previously, the decorator transformer was annotating the synthesized properties with TS type annotations. However, because it ran after the JSDoc transformer, the TS types were just dropped from the emitted JS. Attempting to move the decorator transformer before the JSDoc transformer causes tsickle crashes because synthetic AST fragments are not attached to a SourceFile node.

PR Close #43021
2021-08-25 15:05:29 -07:00
Alex Rickabaugh b8183614f5 release: cut the v12.2.3 release (#43257)
PR Close #43257
12.2.3
2021-08-25 14:20:31 -07:00
George Kalpakas b46ce7d42f build(docs-infra): upgrade cli command docs sources to 56c5962df (#43239)
Updating [angular#12.2.x](https://github.com/angular/angular/tree/12.2.x) from
[cli-builds#12.2.x](https://github.com/angular/cli-builds/tree/12.2.x).

##
Relevant changes in
[commit range](https://github.com/angular/cli-builds/compare/7c2d76d9e...56c5962df):

**Modified**
- help/lint.json

PR Close #43239
2021-08-25 10:48:04 -07:00
Daniel Trevino 36bf0ae985 test(language-service): add test for extended diagnostics (#43134)
Add a test to make sure extended template diagnostics are being correctly
generated in the language service for non-ts files.

Refs #42966

PR Close #43134
2021-08-25 10:43:02 -07:00
Daniel Trevino 3b317dcf87 refactor(compiler-cli): integrate extended diagnostics with the language service (#43134)
Add the call to get the extended template diagnostics in
the compiler's `getDiagnosticsForComponent`. This makes showing
extended diagnostics in non-ts files posible.

Refs #42966

PR Close #43134
2021-08-25 10:43:02 -07:00
Daniel Trevino 3ad527d86e refactor(compiler-cli): rename ExtendedTemplateChecker get diagnostics fucntion (#43134)
Rename `getExtendedTemplateDiagnosticsForComponent` to
`getDiagnosticsForComponent` since it's implied they are extended
diagnostics.

Refs #42966

PR Close #43134
2021-08-25 10:43:02 -07:00
Daniel Trevino b6ff762e36 refactor(compiler-cli): move getDiagnosticsForComponent to compiler (#43134)
Change the language service to call `getDiagnosticsForComponent` from
the compiler instead of the `TemplateTypeChecker`.

Refs #42966

PR Close #43134
2021-08-25 10:43:02 -07:00
Daniel Trevino e196311e5c refactor(compiler-cli): move ExtendedTemplateChecker to LazyCompilationState (#43134)
Create the `ExtendedTemplateChecker` during `makeCompilation`, that way
it's avaiblable in the whole compiler.

Refs #42966

PR Close #43134
2021-08-25 10:43:01 -07:00
Daniel Trevino 3cf8f66f3a refactor(compiler-cli): use TemplateDiagnostic in extended package (#43134)
Return `TemplateDiagnostic` instead of `ts.Diagnostic` when getting the
extended template diagnostics. This makes the integration with the
language service easier. This also fixes the error code and now uses the
`ngErrorCode` for extended template diagnostics.

Refs #42966

PR Close #43134
2021-08-25 10:43:01 -07:00
dario-piotrowicz d7b6416fcf refactor(common): fix emiting typos (#43221)
fix some of the aio examples which log strings containing "emiting" instead of "emitting"

PR Close #43221
2021-08-23 13:30:29 -07:00
shlasouski fc7f92159d fix(service-worker): NPE if onActionClick is undefined (#43210)
Previously, it leads to fail if notification.data.onActionClick is undefined

PR Close #43210
2021-08-23 13:29:59 -07:00
Daniel Trevino cb8e51f8cf test(language-service): add extended diagnostics test (#43107)
Add a test in the langauge-service to make sure the extended template
diagnostics are being correctly generated.

Refs #42966

PR Close #43107
2021-08-19 11:55:28 -07:00
Daniel Trevino e6b2bedd70 test(compiler-cli): add extended template diagnostics end-to-end tests (#43107)
This commit adds extended template diagnostics end-to-end tests, to make
sure the diagnostics are generated correctly. Template checks are
already tested with unit tests.

Refs #42966

PR Close #43107
2021-08-19 11:55:28 -07:00
Daniel Trevino 58a19a3021 refactor(compiler-cli): add extendedTemplateCheck phase to compiler (#43107)
This commit integrates extended template checks with the compiler, by
adding another phase of diagnostics generation. This integration is
under the `_extendedTemplateDiagnostics` flag.

Refs #42966

PR Close #43107
2021-08-19 11:55:28 -07:00
Daniel Trevino f70d2a2981 refactor(compiler-cli): export ExtendedTemplateCheckerImpl and template checks (#43107)
This commit exports the implementation of `ExtendedTemplateChecker` to
generate extended template diagnostics and all the template checks.

Refs #42966

PR Close #43107
2021-08-19 11:55:28 -07:00