13786 Commits

Author SHA1 Message Date
Joey Perrott 97180abd44 build: migrate @angular/upgrade examples tests to new esbuild (#62907)
Migrate to the new esbuild

PR Close #62907
2025-07-30 17:37:14 +00:00
Joey Perrott 280f1f59e1 test(language-service): update language-service legacy tests (#62900)
Update the language-service legacy tests to use new toolchain as basis for tests

PR Close #62900
2025-07-30 15:54:59 +00:00
Jessica Janiuk 82fcc9c136 Revert "fix(http): add missing http options allowed in fetch API (#62881)" (#62899)
This reverts commit ab6033979a.

PR Close #62899
2025-07-30 14:35:36 +00:00
SkyZeroZx ab6033979a fix(http): add missing http options allowed in fetch API (#62881)
The addBody function was not preserving all fetch API options like integrity and referrer when creating request options for POST/PUT/PATCH requests. This caused these options to be stripped out during request construction.

PR Close #62881
2025-07-30 14:07:42 +00:00
Matthieu Riegler 25c6b1547f refactor(core): add private resource error helper function for g3 migration (#62840)
This function is intented to be temporary to help migrate G3 code to the new throwing behavior.

PR Close #62840
2025-07-30 09:23:11 +00:00
Joey Perrott 775f918192 build: remove usages of rules_nodejs (#62885)
Remove rules_nodejs usages with direct migrations to rule_js alternatives

PR Close #62885
2025-07-30 08:51:28 +00:00
Matthieu Riegler db3c5826ee fix(compiler): exclude more safe reads expression from 2way-binding (#62852)
Priori to this fix the parser would allow safereads in accestor receievers (but the direct one).

fixes #62837

PR Close #62852
2025-07-29 17:28:08 +00:00
arturovt 8ddf5e4dc1 refactor(service-worker): align getRegistration() types (#62497)
In this commit, we align the service worker types with those provided by TypeScript. The `ServiceWorkerContainer.getRegistration()` method returns a `Promise<ServiceWorkerRegistration | undefined>`, but we were casting it to `Observable<ServiceWorkerRegistration>`, ignoring the possibility of `undefined`.

This is unsafe, as we should account for the case where the registration is `undefined` and handle it appropriately in the push manager.

PR Close #62497
2025-07-29 17:25:03 +00:00
Joey Perrott c9fb4e31dd build: use ts_project based extract_types (#62875)
Use the extract_types that pulls from ts_project deps

PR Close #62875
2025-07-29 17:14:27 +00:00
Joey Perrott ea1afec1e4 build: move http_server and generate_api_docs into defaults2.bzl (#62878)
Move http_server and generate_api_docs into defaults2.bzl as they are rules_js compliant

PR Close #62878
2025-07-29 16:53:55 +00:00
Matthieu Riegler 0b9f53a05d docs: fix ActivateRoute example (#62855)
PR Close #62855
2025-07-29 12:17:46 +00:00
Matthieu Riegler f0fca612ee refactor(common): replace aio links to adev (#62839)
The is a doc change + a minor test change (to remove test logs that mention aio)

PR Close #62839
2025-07-29 09:55:26 +00:00
Joey Perrott 622e10881f build: standardize usage of js_binary (#62860)
Remove usages of nodejs_binary and use a commonly defined js_binary macro

PR Close #62860
2025-07-29 06:43:45 +02:00
Joey Perrott 2b16824110 build: move tsec to new toolchain (#62825)
Migrate tsec tooling/macro to use tsec directly as a js_binary and rely on ts_project dependencies.

PR Close #62825
2025-07-28 20:07:05 +02:00
Milo c633b63e56 fix(core): update symbols for new signals api (#62284)
approve the new symbols that appear from bundling the signals changes

PR Close #62284
2025-07-28 17:01:43 +02:00
Milo ce2cd9e7a0 refactor(core): use quad linked lists for signals (#62284)
inspired by the design of Preact's signals, use linked lists instead of arrays for faster signal creation

PR Close #62284
2025-07-28 17:01:43 +02:00
Joey Perrott 14d998d809 build: use rollup to locally bundle domino (#62823)
Use rollup instead of esbuild for bundling domino locally for usage within the repository

PR Close #62823
2025-07-28 14:19:57 +02:00
Joey Perrott 973740e14a build: migrate zone.js tests to use web test runner instead of karma web tests (#62826)
Migrate zone.js bazel tests to use web test runner instead of karma

PR Close #62826
2025-07-28 14:18:46 +02:00
Joey Perrott b6f52c3111 build: move from using rollup to esbuild for bundling zone.js (#62800)
Use esbuild to bundle zone.js

PR Close #62800
2025-07-25 16:54:20 +02:00
Andrew Scott 715d5ce192 build: Export language service bundle (#62811)
fixes Plugin activation failed: Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './bundles/language-service.js' is not defined by 'exports'

PR Close #62811
2025-07-25 16:52:00 +02:00
Angular Robot c11f7b991f build: update cross-repo angular dependencies (#62807)
See associated pull request for more information.

PR Close #62807
2025-07-25 14:32:17 +02:00
Joey Perrott dce0609755 build: use ts_config rule from rules_ts only and always load from common location (#62808)
Only use the ts_config rule from rules_ts, and always load the rule from tools/defaults2.bzl

PR Close #62808
2025-07-25 10:08:13 +02:00
Joey Perrott 2b0f3fc7cb build: remove all usages of @bazel/runfiles (#62805)
Remove usages of @bazel/runfiles throughout the repository

PR Close #62805
2025-07-25 10:05:54 +02:00
Garegin Hakobyan 82862deab8 docs(docs-infra): correct typos in adev and wording in resource api (#62801)
PR Close #62801
2025-07-24 16:13:00 +00:00
SkyZeroZx 206d153301 refactor(forms): Removes redundant destroy ref usage in value accessor in select control (#62738)
Simplifies destruction logic by relying directly on the injector's destroyed state.
Eliminates unnecessary retrieval of a separate destroy reference

PR Close #62738
2025-07-24 13:25:31 +00:00
Angular Robot 187cb9cd10 build: update cross-repo angular dependencies (#62790)
See associated pull request for more information.

PR Close #62790
2025-07-24 11:27:30 +00:00
Angular Robot e2e1cb6def build: lock file maintenance (#62794)
See associated pull request for more information.

Closes #62622 as a pr takeover

PR Close #62794
2025-07-24 10:59:16 +00:00
Andrew Scott a967f92078 test(router): Use autoTick feature in router tests (#62776)
This updates async router tests to use the jasmine autoTick feature. Observed test timings
for the chromium tests went down from ~7.5s to ~3.5-4s. For node, these decreased from ~5.5s to ~3s.

In addition to the speed improvement, this feature:

* Removes the need to be careful about timeout ordering when there are several timeouts in tests.
* Removes the need to ensure test timeouts are kept sufficiently small
* Reduces overall flakiness

PR Close #62776
2025-07-24 10:04:06 +00:00
Sebastian Barfurth 15670d8417 fix(http): propagate plain errors when parsing fails (#62765)
The fetch backend now propagates the plain body when parsing the body fails.
This replicates the behavior of the XHR backend introduced in #19773.

The current state completely obfuscates errors of the "wrong" response type.
However, it's not uncommon for successful requests to return one type and
errors to return another type. Propagating the plain error allows downstream
error consumers to reason about the error body and decide how to parse it
depending on application needs.

PR Close #62765
2025-07-24 09:23:24 +00:00
Matthieu Riegler a83ef0ecdf refactor(compiler): Error on comment only interpolations (#62590)
This commit introduces a ParserError to prevent an error later in the pipepine

fixes #34084

PR Close #62590
2025-07-24 09:19:47 +00:00
Kristiyan Kostadinov 2fd1f7beb5 fix(platform-browser): resolve component resources before bootstrapping in JIT mode (#62758)
Currently if the app has some external resources and it gets bootstrapped in JIT mode, the user will get an error about calling `resolveComponentResources`. These changes add a call to `resolveComponentResources` automatically inside `bootstrapApplication`.

Note that we don't need similar logic for `bootstrapModule`, because it calls into `compileNgModuleFactory` internally which in turn calls `resolveComponentResources`.

PR Close #62758
2025-07-23 11:05:20 -04:00
Joey Perrott db8f7ce0ba build: move generating doc files for @angular/ssr to using an intermediate typescript file (#62734)
Use an intermediate typescript file to rexport all of all of @angular/ssr rather than reaching into the npm package files

PR Close #62734
2025-07-22 10:13:28 -04:00
Joey Perrott 807c4d7973 build: move nodejs_test to js_test (#62711)
Move nodejs_test to js_test and remove unnecessary files after move

PR Close #62711
2025-07-22 10:10:18 -04:00
Matthieu Riegler 38b7ab26fb refactor(core): add a getTransferState for the devtools (#62722)
`getTransferState` will expose public data from the transfer state. It will for example remove internal hydration data.

PR Close #62722
2025-07-21 17:00:28 -04:00
Joey Perrott b388f1e518 build: remove all usages of the interop_deps attr for ts_project and ng_project (#62733)
Remove all of the usages of interop_deps as attributes in the repo

PR Close #62733
2025-07-21 13:10:18 -04:00
Angular Robot c36de9e6ca build: update cross-repo angular dependencies (#62651)
See associated pull request for more information.

PR Close #62651
2025-07-18 10:19:36 -04:00
Elizabeth 2c522efbe5 fix(core): fix change tracking for Resource#hasValue (#62595)
When using `hasValue()` I would expect it to behave like any other
reactive value such that changes to the internal `value()` that do not
cause `hasValue()` to return anything different do not trigger change
detection, but this was not the case. This change wraps the value
checking in a `computed` such that it behaves as expected again while
still preserving the type narrowing.

PR Close #62595
2025-07-18 10:01:44 -04:00
Andrew Scott ba8a5d826e refactor(core): Use promise.finally for task removal (#62674)
Updates the approach from https://github.com/angular/angular/pull/62631 to
use Promise.finally for task removal. This is a bit cleaner and also handles
rejections from the donePromise

PR Close #62674
2025-07-18 07:19:49 -04:00
Joey Perrott 1e9bfe54b1 build: migrate to new toolchain usage for api goldens (#62688)
Migrate api golden usage to be based on rules_js toolchain implementation

PR Close #62688
2025-07-17 18:13:43 -04:00
Matthieu Riegler 8ad10fd63b fix(compiler): fix detection of directive deps in JIT (#62666)
This fix also matches the implementation to the jsdoc for `hasDirectiveDependencies` "Whether any of the component's dependencies are directives"

fixes #62573

PR Close #62666
2025-07-17 14:20:32 -04:00
Joey Perrott c2625575aa build: remove ts_library definition (#62686)
Remove the ts_library macro from our defaults.bzl file

PR Close #62686
2025-07-17 14:16:02 -04:00
Joey Perrott 8b62b313e1 build: migrate zone.js to use ts_project instead of ts_library (#62686)
Use ts_project instead of ts_library for building zone.js

PR Close #62686
2025-07-17 14:16:02 -04:00
Joey Perrott 0db3613565 build: remove rules_nodejs based protractor tooling (#62649)
Remove the protractor setup based on rules_nodejs

PR Close #62649
2025-07-16 16:39:50 -04:00
Joey Perrott 3e8e16bce7 build: migrate protractor test to new toolchain (#62649)
Migrate to new toolchain for protractor test in packages/examples/upgrade

PR Close #62649
2025-07-16 16:39:50 -04:00
Kristiyan Kostadinov 9506cdfaad fix(compiler-cli): infer type of event target for void elements (#62648)
Currently we infer the target of DOM events to be `EventTarget | null` which is consistent with the built-in types for `addEventListener`. This is due to the fact that users can dispatch custom events, or the event might've bubbled. However, this typing is also inconvenient for some other common use cases like `<input (input)="query($event.target.value)">`, because we don't have the ability to type cast in a template.

These changes aim to make some of the cases simpler by inferring the type of `$event.target` if the event is bound on a void element which guarantees that it couldn't have bubbled.

PR Close #62648
2025-07-16 12:40:26 +02:00
Kristiyan Kostadinov 2ab638d514 refactor(core): expose function to assert type of variables (#62648)
Adds the `ɵassertType` function that will be used during type checking to assert the type of a value.

PR Close #62648
2025-07-16 12:40:26 +02:00
Kristiyan Kostadinov 53963e910e refactor(compiler): indicate whether element is void at AST level (#62648)
Updates the HTML AST to indicate whether a specific element is a void element.

PR Close #62648
2025-07-16 12:40:25 +02:00
Kristiyan Kostadinov 70c8780c54 fix(compiler): more permissive parsing of @ characters (#62644)
When we introduced blocks, we made a deliberate decision to treat the `@` character as a reserved character in case we need to use it for other syntax in the future. This meant that some common cases, like writing out an email address in the template, can be broken.

After some recent discussions we decided to relax the requirement and only treat `@` as a reserve character if it's followed by a character sequence that matches a known block.

PR Close #62644
2025-07-15 13:24:47 -07:00
Kristiyan Kostadinov f531370281 test(compiler): remove duplicated lexer tests (#62644)
There were 26 duplicated block tests in `lexer_spec.ts`, likely due to merge conflicts. These changes remove the duplicates while keeping the 6 tests that were different.

PR Close #62644
2025-07-15 13:24:47 -07:00
Kristiyan Kostadinov 75d2a349b4 fix(compiler): incorrect spans for left side of binary operation (#62641)
Fixes that the span for the `left` side of a `Binary` AST included the range up to and including the operator.

Fixes #62617.

PR Close #62641
2025-07-15 07:57:32 -07:00