https://github.com/angular/angular

sort by:
Revision Author Date Message Commit Date
7bfa361 release: cut the v17.3.0-rc.0 release 06 March 2024, 19:40:30 UTC
4be9632 docs: release notes for the v17.2.4 release 06 March 2024, 19:34:37 UTC
7243c70 fix(core): return a readonly signal on `asReadonly`. (#54706) Previous `asReadonly()` returned the signal value and not the signal itself. Fixes #54704 PR Close #54706 06 March 2024, 13:41:12 UTC
e5885fa build: update ng-dev to avoid node-fetch usages (#54715) See: https://github.com/angular/dev-infra/pull/1829 PR Close #54715 06 March 2024, 12:16:38 UTC
d4154f9 refactor(core): revert listener subscription typeof check (#54650) For model signals we introduced some sniffing on the return type of a `.subscribe` invocation- allowing for subscribe to _just_ return a callback directly to unsubscribe. This works in practice, but the positive `tCleanup` indices have more meaning, especially in the context of `DebugElement`. A positive index indicates a DOM event- so we need to revert this change. This now surfaced as we made `EventEmitter` return a function + the subscription via a proxy that ended up `typeof function` --> and broke some tests where debug element incorrectly invoked non-dom outputs as dom listeners. We don't need this change with current unsubscribe function concept. PR Close #54650 06 March 2024, 11:34:39 UTC
2df8584 refactor(compiler-cli): speed up compiler tests by caching Angular (#54650) Currently the `makeProgram` utility from `ngtsc/testing` does not use the test host by default- optimizing for source file caching. Additionally, the host can be updated to attempt caching of the `.d.ts` files from `@angular/core`— whether that's fake core, or the real core- is irrelevant. We are never caching if these changes between tests, so correctness is guaranteed. This commit reduces the type check test times form 80s to just 11 seconds, faster than what it was before with `fake_core`. The ngtsc tests also run significantly faster. From 40s to 30s PR Close #54650 06 March 2024, 11:34:39 UTC
8a8b682 test: integration test for `output()` api (#54650) Adds an integration test for `output()` and `outputFromObservable()`. The test verifies the JIT transform as well. PR Close #54650 06 March 2024, 11:34:39 UTC
6b1401a test: add compiler ngtsc tests for new `outputFromObservable` API (#54650) Adds additional ngtsc compiler tests for the `outputFromObservable` API. PR Close #54650 06 March 2024, 11:34:39 UTC
ea03104 test: fix global augmentation leaking into all source files (#54650) The `inject` global augmentation from upgrade tests, leak into all source files for IDEs, making it easy to run into issues when actually trying to deal with `inject` from Angular core for DI. PR Close #54650 06 March 2024, 11:34:39 UTC
400b739 test: add language-service tests for `outputFromObservable()` (#54650) Adds additional language-service tests for `outputFromObservable()`. Existing tests already verify the behavior for `output()`. PR Close #54650 06 March 2024, 11:34:39 UTC
500a13e refactor(core): enforce `model()` and `output()` is used in an injection context (#54650) Technically `model()` and `output()` already need to be defined in an injection context- because `OutputRef` requires this. To improve the error messaging, this commit asserts this as part of the top-level entry functions for `model()` and `output()`. Without this change, the error would mention the `_createOutputRef` internal function. PR Close #54650 06 March 2024, 11:34:39 UTC
db7962a test: add runtime tests for `output()` function API (#54650) Adds runtime acceptance tests for `output()` and `outputFromObservable()`. PR Close #54650 06 March 2024, 11:34:39 UTC
866271a refactor(core): `EventEmitter` implements `OutputRef`. (#54650) An `EventEmitter` is a construct owned by Angular that should be used for outputs as of right now. As we are introducing the new `OutputRef` interface for the new output function APIs, we also think `EventEmitter` should implement `OutputRef`— ensuring all "known" outputs follow the same contract. This commit ensures `EventEmitter` implements an `OutputRef` Note: An output ref captures the destroy ref from the current injection context for clean-up purposes. This is also done for `EventEmitter` in a backwards compatible way: - not requiring an injection context. EventEmitter may be used elsewhere. - not cleaning up subscriptions/completing the emitter when the directive/component is destroyed. This would be a change in behavior. Note 2: The dependency on `DestroyRef` causes it to be retained in all bundling examples because ironically `NgZone` uses `EventEmitter`- not for outputs. The code is pretty minimal though, so that should be acceptable. `EventEmitter` will now always retain `NgZone. This increases the payload size slightly around 800b for AIO. Note that the other increases were coming from previous changes. This commit just pushed it over the threshold. PR Close #54650 06 March 2024, 11:34:39 UTC
30355f6 refactor(core): `model()` implements `OutputRef` (#54650) A model signal is technically an output, at runtime and conceptually. This commit re-uses the shared output ref logic and ensures the interfaces match. PR Close #54650 06 March 2024, 11:34:38 UTC
e7ea6c0 test: add compliance generated output tests for `output()` (#54650) This commit adds compliance tests for the new output APIs. PR Close #54650 06 March 2024, 11:34:38 UTC
aff65fd feat(core): introduce `outputToObservable` interop helper (#54650) This commit introduces an addition to `output()` and `outputFromObservable`()` —called `outputToObservable()`. The helper lives in the RxJS interop package and allows agnostic programmatic subscriptions to `OutputRef`s by converting the output to an observable with `.pipe` etc. The function is ideally used in all places where you subscribe to an output programmatically. Those outputs in the future, with the new APIs, may not be actual RxJS constructs, but abstract `OutputRef`'s that simply expose a `.subscribe` method. The helper allows you to agnostically convert outputs to RxJS observables that you can safely interact with. The observables are also completed automatically, if possible, when the owning directive/component is destroyed— Something that is not guaranteed right now. PR Close #54650 06 March 2024, 11:34:38 UTC
c809069 feat(core): introduce `outputFromObservable()` interop function (#54650) Introduces a second API in addition to the new `output()` function. The new function `outputFromObservable()` can be used to declare outputs using the new `OutputRef` API and `output()` API, while using a custom RxJS observable as data source. This is something that is currently possible in Angular and we would like to keep possible- even though we never intended to support custom observables aside from RxJS-based `EventEmitter`. The interop bridges the gap and allows you to continue using `Subject`, `ReplaySubject`, `BehaivorSubjct,` - or cold custom observables for outputs. You can still trigger logic only when the output is subscribed- unlike with imperative `emit`s of `EventEmitter` or the new `OutputEmitterRef`. A notable difference is that you need two class members where you previously could access the `Subject` directly. This is an intentional trade-off we've made to ensure that all new outputs implement the `OutputRef` interface and we are exposing a minimal API surface to consumers of components that currently access the output programmatically. PR Close #54650 06 March 2024, 11:34:38 UTC
9b51292 refactor(compiler-cli): support detecting initializer APIs from different modules (#54650) This commit allows us to detect initializer APIs like `outputFromObservable` that are declared in different modules- not necessarily `@angular/core`. PR Close #54650 06 March 2024, 11:34:38 UTC
c687b8f feat(core): expose new `output()` API (#54650) This commit exposes the new `output()` API with numerous benefits: - Symmetrical API to `input()`, `model()` etc. - Fixed types for `EventEmitter.emit`— current `emit` method of `EventEmitter` is broken and accepts `undefined` via `emit(value?: T)` - Removal of RxJS specific concepts from outputs. error channels, completion channels etc. We now have a simple consistent interface. - Automatic clean-up of subscribers upon directive/component destory- when subscribed programmatically. ```ts @Directive({..}) export class MyDir { nameChange = output<string>(); // OutputEmitterRef<string> onClick = output(); // OutputEmitterRef<void> } ``` Note: RxJS custom observable cases will be handled in future commits via explicit helpers from the interop. PR Close #54650 06 March 2024, 11:34:38 UTC
9ce6277 refactor(core): create `OutputRef` runtime construct (#54650) This commit creates the proposed `OutputRef` interface along with `OutputEmitterRef`: - `OutputRef` is the consistent interface for all Angular outputs. - `OutputEmitterRef` is an extension for emitting values. Like `EventEmitter`. - subscriptions are cleaned up automatically upon directive/component destroy. - emitting is an error when destroyed - subscribing programmatically is an error when already destroyed. This commit will also implement the shared output ref runtime construct, that can be used by `output()`, `outputFromObservable()` and `model()`. We will manage subscriptions in a simple way, manually, without RxJS. PR Close #54650 06 March 2024, 11:34:38 UTC
2564b45 test: replace `fake_core` with real `@angular/core` output (#54650) This commit replaces `fake_core` with the real `@angular/core` output. See previous commit for reasons. Overall, this commit: * Replaces references of `fake_core` * Fixes tests that were testing Angular compiler detection that _would_ already be flagged by type-checking of TS directly. We keep these tests for now, and add `@ts-ignore` to verify the Angular checks, in case type checking is disabled in user applications- but it's worth considering to remove these tests. Follow-up question/non-priority. * Adds `@ts-ignore` to the tests for `defer` 1P because the property is marked as `@internal` and now is (correctly) causing failures in the compiler test environment. * Fixes a couple of tests with typos, wrong properties etc that previously weren't detected! A good sign. PR Close #54650 06 March 2024, 11:34:38 UTC
5afa4f0 fix(compiler-cli): support `ModuleWithProviders` literal detection with `typeof` (#54650) As part of improving test safety of the compiler, I've noticed that we have a special pass for detecting external `ModuleWithProviders` where we detect the module type from an object literal. This literal is structured like the following: `{ngModule: T}`. The detection currently takes `T` directly, but in practice it should be `typeof T` to satisfy the `ModuleWithProviders` type that is accepted as part of `Component#imports`. This commit adds support for this, so that we can fix the unit test in preparation for using the real Angular core types in ngtsc tests. PR Close #54650 06 March 2024, 11:34:38 UTC
bd60fb1 docs: update Angular CLI help [main] (#54712) Updated Angular CLI help contents. PR Close #54712 06 March 2024, 09:34:11 UTC
4842eed fix(docs-infra): do not delete `BUILD.bazel` in help directory during updates (#54697) In https://github.com/angular/angular/pull/54591, a `BUILD.bazel` file was created in `aio/content/cli/help/BUILD.bazel`, this however breaks the automatic CLI help pages updates as prior to this change, the `help` directory was being deleted. See: https://github.com/angular/angular/pull/54691/commits/17346e89da2fbddf8274eeadf12bab9c5b8983d8 This commit, updates the process to delete only the JSON files and copying the new files. PR Close #54697 06 March 2024, 09:18:03 UTC
755390a docs: add process documentation to CARETAKER.md (#54664) This adds documentation regarding the latest changes to framework merge tools. It specifically covers the requires: TGP label and separate sync for primitives. PR Close #54664 05 March 2024, 18:11:41 UTC
d2ec5b6 docs: fix clipped `docs-code` block in `docs-reference-api-tab` (#54621) PR Close #54621 05 March 2024, 17:35:09 UTC
b5366f2 docs: fix tutorial preview size (#54621) PR Close #54621 05 March 2024, 17:35:06 UTC
40424fc docs: fix label on API link. (#54621) Remove the unecessary double quotes on a @see link. PR Close #54621 05 March 2024, 17:35:04 UTC
70996ed docs(docs-infra): remove unwanted styling on API page. (#54621) `box-sizing: border-box` prevents overflow caused by borders. PR Close #54621 05 March 2024, 17:35:02 UTC
0ecf515 ci: fix ng-dev build for pr merging (#54707) This updates ng-dev to the latest hash fixing the merge files query. PR Close #54707 05 March 2024, 17:16:30 UTC
b40f1e5 refactor(compiler): Remove deep imports in the language service (#54695) Previously, the language service relied on deep imports such as `@angular/compiler/render3/...`. This is bad form, because that creates a dependency on the package's internal structure. Additionally, this is not compatible with google3. In this PR, I replace all the deep imports with shallow imports, in some cases adding the missing symbol to the `compiler.ts` exports. PR Close #54695 05 March 2024, 09:28:45 UTC
33a6fab fix(core): apply TestBed provider overrides to `@defer` dependencies (#54667) This commit updates TestBed logic to take into account situations when dependencies loaded within `@defer` blocks may import NgModules with providers. For such components, we invoke provider override function, which recursively inspects and applies the necessary changes. PR Close #54667 05 March 2024, 08:21:22 UTC
78e6911 fix(core): generic inference for signal inputs may break with `--strictFunctionTypes` (#54652) This commit fixes that the generic inference for signal inputs may break with `--strictFunctionTypes`. We are not using --strictFunctionTypes` in all tests, so function parameters are always checked bivariantly- while in 1P function parameters are checked contravariantly. This breaks sub-typing and e.g. `InputSignal<number>` is not a subtype of `InputSignalWithTransform<unknown, number>`. Root cause is that the input signal captures the equality function that is exclusively concerned with the `ReadT`. And `ReadT` is never equal, or a supertype of unknown. https://www.typescriptlang.org/play?#code/KYDwDg9gTgLgBASwHY2FAZgQwMbDgSSTAFcYBlBAcyUwBsB1BGACwBUpMkBndaAWwA8AJWCYAJqwA0celCbBWAPjgBvAFBw4Aei1xWACXxlEXOCzxQIEeNkzEuwAIRmAnmDxhMHPsFRRTXnjYzMDYANbAYnDYECgcAG5eCJwwtC7SAHIA8qxwAEYIALSJcilpAHQacMAAjsR0AFxwABSYTSLiUvntohIAlHAAvMp5VrSiSADcalUA+rNQvaw9ndOa8wDucqjLMtsK0wC+aqCQsIgoaFi4BESkFNR0wkuKVaCoSGKmhCTkVDQMJhsDjcXhQQQdCTSSFKVTHNQxbjwEBNH73f50RgsdicHj8ATEJBhJAQDZIaRIYh8PJoZSDKqU2i0ZyYb53P6PWgCSnU2nTKpaABUM00rDceAA5GiOQDuVSaVBFBKTHASfBWVwMXlxmYIK53HApeyHgCscDcWDBITiaTyar5bSJZVReLTBB0HAwJZ3LAXIbavVaMrAhcYnxPDAENrgM7NHpxYbWk0eQrpHlkw6oANhvkxhNlQhTGq4BqtTqYHqYAmJUm4NaSWS00167bsyM85wnVU4-H3G6PZ5vL40KYJZhg59DeOS4tQxBw5hI9HYz2XQaJS2yQWi9YS1xNY9o7r9ZKU2gnc0AEwzDTZVgAUSaABF7wAFe8ZF8ZXJZDJwAAGhSFFwMByNgMAAGKEuBCCxGKfb-nA6C0JglArqugpaEAA PR Close #54652 04 March 2024, 18:07:39 UTC
5e32a77 refactor(compiler): cleanup unused code in template builder pipeline (#54654) This removes some unused code and fixes a few typos across the pipeline code. PR Close #54654 04 March 2024, 17:15:54 UTC
6531e4c ci: Add primitives configurations for ng-dev tools (#54662) This adds the configs to enable validators and google sync patterns for primitives sharing. PR Close #54662 04 March 2024, 16:41:17 UTC
07d5e42 docs: revise documentation for @for control flow, 'track $index' performance issues explanation, and confusing 'trackBy' mention (#53806) PR Close #53806 04 March 2024, 10:37:37 UTC
0ddae16 docs: queries as signals adev guide (#54505) Add a angular.dev version of queries as signals guide. PR Close #54505 04 March 2024, 10:11:16 UTC
07173fd refactor(core): Pending effects should make the application unstable (#53835) In zone-full applications, this is already true because effects are scheduled inside a microtask and tracked by ZoneJS. When not using zones, this should stay consistent on principle and for testability reasons. A general pattern with zoneless testing will be to update state and `await` some promise (i.e. `fixture.whenStable`, which will be linked to `ApplicationRef.isStable`). PR Close #53835 04 March 2024, 09:35:38 UTC
0d98972 docs(docs-infra): Update tutorial deps (#54677) PR Close #54677 04 March 2024, 09:03:14 UTC
3e703f5 docs: fix broken link on the tutorial page (#54669) PR Close #54669 03 March 2024, 12:59:02 UTC
66d78a7 refactor(core): ComponentFixture autodetect should detect changes within ApplicationRef.tick (#54354) The current behavior of `autoDetect` in `ComponentFixture` does not match production very well. It has several flaws that make it an insufficient change detection mechanism: * It runs change detection for the component under test _after_ views attached to the `ApplicationRef`. This can cause real behavior differences that break in production, because tests can observe view refreshes in the incorrect order (for example, a dialog refreshing before the component which opened it). * Because of the above ordering, render hooks registered during change detection of the fixture views _will not execute at all_ because `ApplicationRef.tick` already happen. * It does not rerun change detection on the view tree if there are more dirty views to refresh after the render hooks complete. * It effectively hides/swallows errors from change detection inside the `onMicrotaskEmpty` subscription by not reporting them to the error handler. Instead, this error ends up being unhandled in the subscription and rxjs throws these in a `setTimeout`. All of the above are problematic but this commit _does not_ fix the final point. Ideally, we can land this in a future change but this requires additional internal fixes. In the meantime, we have to juggle special-case handling of the component fixture views within `ApplicationRef.tick` using some special events to retain current behavior and avoid errors from the fixture propagating to the `ErrorHandler`. breaking note for future when isG3 flag condition is removed for v18: The `ComponentFixture.autoDetect` feature now executes change detection for the fixture within `ApplicationRef.tick`. This more closely matches the behavior of how a component would refresh in production. The order of component refresh in tests may be slightly affected as a result, especially when dealing with additional components attached to the application, such as dialogs. Tests sensitive to this type of change (such as screenshot tests) may need to be updated. PR Close #54354 01 March 2024, 04:53:09 UTC
b322079 refactor(core): remove unused `EffectRef` import statement (#53863) Remove unused, leftover imports. PR Close #53863 29 February 2024, 13:54:50 UTC
ffad7b8 fix(core): untrack various core operations (#54614) One downside of implicit dependency tracking in `effect()`s is that it's easy to for downstream code to end up running inside the effect context by accident. For example, if an effect raises an event (e.g. by `next()`ing a `Subject`), the subscribers to that `Observable` will run inside the effect's reactive context, and any signals read within the subscriber will end up as dependencies of the effect. This is why the `untracked` function is useful, to run certain operations without incidental signal reads ending up tracked. However, knowing when this is necessary is non-trivial. For example, injecting a dependency might cause it to be instantiated, which would run the constructor in the effect context unless the injection operation is untracked. Therefore, Angular will automatically drop the reactive context within a number of framework APIs. This commit addresses these use cases: * creating and destroying views * creating and destroying DI injectors * injecting dependencies * emitting outputs Fixes #54548 There are likely other APIs which would benefit from this approach, but this is a start. PR Close #54614 29 February 2024, 10:38:54 UTC
9a8a544 docs(docs-infra): remove the override for piscina (#54656) PR Close #54656 29 February 2024, 10:07:07 UTC
c1c7384 feat(router): Add reusable types for router guards (#54580) This refactor makes it easier to update the return types of guards. Rather than having to track what types guards can return, which may change with new features over time, `MaybeAsync<GuardResult>` can be used instead. PR Close #54580 28 February 2024, 17:09:33 UTC
fb540e1 feat(core): add migration for invalid two-way bindings (#54630) As a part of #54154, an old parser behavior came up where two-way bindings were parsed by appending `= $event` to the event side. This was problematic, because it allowed some non-writable expressions to be passed into two-way bindings. These changes introduce a migration that will change the two-way bindings into two separate input/output bindings that represent the old behavior so that in a future version we can throw a parser error for the invalid expressions. ```ts // Before @Component({ template: `<input [(ngModel)]="a && b"/>` }) export class MyComp {} // After @Component({ template: `<input [ngModel]="a && b" (ngModelChange)="a && (b = $event)"/>` }) export class MyComp {} ``` PR Close #54630 28 February 2024, 17:06:23 UTC
ae7dbe4 fix(compiler-cli): unwrap expressions with type parameters in query read property (#54647) Fixes that a query like `viewChild('locator', {read: ElementRef<HTMLElement>})` would throw because we didn't account for expressions with type parameters. I've also included support for parenthesized expressions and `as` expressions since it's pretty easy to support them. Fixes #54645. PR Close #54647 28 February 2024, 17:05:13 UTC
d7c6865 build: update to the TypeScript 5.4 RC (#54643) Updates the repor to the release candidate of the TypeScript 5.4. PR Close #54643 28 February 2024, 16:43:17 UTC
06ffe9a docs: updated setting up Zone.js instructions (#52409) Updated the "Setting up Zone.js" instructions to the latest convention from how the Angular CLI configures it. Include adding zone-flats.ts to the tsconfig.app.json file step. Added src/ to zone-flag.ts in the code example. PR Close #52409 28 February 2024, 16:35:10 UTC
c1590e7 docs: fix broken link in AIO (#54649) Fixes a broken link that is currently breaking the CI. PR Close #54649 28 February 2024, 16:15:06 UTC
1519b5b docs: fix broken markdown syntax (#53567) PR Close #53567 28 February 2024, 14:16:14 UTC
2f875d0 docs: update versioning and deprecation policies (#51423) Add more details around: - What we consider a breaking change - What is a deprecation - How do we guarantee Angular stays stable - Update invalid links PR Close #51423 28 February 2024, 13:38:36 UTC
52970e3 docs: add updating to v17 guide (#52410) PR Close #52410 28 February 2024, 13:19:45 UTC
2e401c7 fix(docs-infra): include CLI reference docs in adev (#54591) include the reference docs in the adev application PR Close #54591 28 February 2024, 11:48:09 UTC
e923545 docs: release notes for the v17.2.3 release 28 February 2024, 00:28:23 UTC
ccda258 release: cut the v17.3.0-next.1 release 28 February 2024, 00:12:02 UTC
df0e69b build: handle commonjs dependencies when bundling language service (#54429) Fixes that the language service bundling would throw if a CommonJS dependency is used. PR Close #54429 27 February 2024, 23:24:24 UTC
7da4591 refactor(compiler-cli): use semver for version parsing (#54429) Follow-up to #54423 which uses `semver` to parse the version instead of doing it ourselves. PR Close #54429 27 February 2024, 23:24:23 UTC
3d6552c docs(docs-infra): update angular/build-tooling and angular/docs (#54555) Fixes #54476, #52603, #52734 PR Close #54555 27 February 2024, 23:22:18 UTC
ff40c9f fix(core): fix typo in injectors.svg file (#54596) this commit fixes the unnecessary single quote in injectors.svg file Closes #54592 PR Close #54596 27 February 2024, 23:21:05 UTC
331b16e feat(core): add API to inject attributes on the host node (#54604) Angular has the `@Attribute` decorator that allows for attributes to be injected from the host node, but we don't have an equivalent for the `inject` function. These changes introduce the new `HostAttributeToken` class that can be used to inject attributes similarly to `@Attribute`. It can be used as follows: ```typescript import {HostAttributeToken, inject} from '@angular/core'; class MyDir { someAttr = inject(new HostAttributeToken('some-attr')); } ``` The new API works similarly to `@Attribute` with one key exception: it will throw a DI error when the attribute doesn't exist, instead of returning `null` like `@Attribute`. We made this change to align its behavior closer to other injection tokens. PR Close #54604 27 February 2024, 23:18:41 UTC
4066e62 ci: use angular/team Github team for minimum review set (#54611) Use the angular/team Github team to define the list of eligible minimum reviewer set so that it can be reused accross the organization PR Close #54611 27 February 2024, 23:17:07 UTC
6470e33 build: update io_bazel_rules_sass digest to 888dd9c (#54615) See associated pull request for more information. PR Close #54615 27 February 2024, 22:06:29 UTC
8f0c27f refactor(docs-infra): apply prettier formatting to adev (#54625) Apply prettier formatting to adev code PR Close #54625 27 February 2024, 22:04:49 UTC
83d8c68 release: bump Angular DevTools version to 1.0.11 (#54631) PR Close #54631 27 February 2024, 22:02:15 UTC
dd9f9d7 Revert "refactor(devtools): implement iframe support for Angular DevTools' browser code (#53934)" (#54629) This reverts commit dd3dac9cc99ac7988e6bff5a3df30786ad0f1155. PR Close #54629 27 February 2024, 22:00:13 UTC
133319e Revert "refactor(devtools): implement multiframe support in devtools page (#53934)" (#54629) This reverts commit ebcdc8dc96e971f68e30cfe4acda5eba87417d77. PR Close #54629 27 February 2024, 22:00:12 UTC
3e0b3a1 refactor: add `--spawn_strategy local` to `--config debug` (#54167) This seems to be necessary to debug Node tests. PR Close #54167 27 February 2024, 02:36:38 UTC
53820dd refactor(core): Internal render hooks trigger view refresh before executing user hooks (#54224) This commit ensures that any internal render hooks that cause views to become dirty again first refresh those dirty views before running user render hooks. This ensures that user render hooks have the most complete render state possible and stops them from needlessly executing multiple times. This is important to maintain the goal of the public render hooks, which is to provide the safest place to place code that depends on DOM state, especially in ways that may force a browser paint. PR Close #54224 27 February 2024, 02:31:13 UTC
46617ce refactor(core): Add helper function for queuing state updates (#54224) This adds a helper function to defer application state updates to the first possible "safe" moment. If application-wide change detection (ApplicationRef.tick) is currently executing when this function is used, the callback will execute as soon as all views attached to the `ApplicationRef` have been refreshed. Refreshing the application views will happen again before `checkNoChanges` executes. When a change detection is _not_ running, this state update will execute in the microtask queue. This function is necessary as a replacement for current `Promise.resolve().then(() => stateUpdate())` to be zoneless compatible while ensuring those state updates are synchronized to the DOM before the browser repaint. Without this, updates done in `Promise.resolve(...)` would queue another round of change detection in zoneless applications, and this change detection could happen in the next browser frame, and cause noticeable flicker for the user. Additionally, this function provides a way to perform state updates that will run on the server as well as in the browser. Last, current applications using `ngZone: 'noop'` may not be calling `ApplicationRef.tick` at all so this function provides a mechanism to ensure the state update still happens by racing a microtask with `afterNextRender` (which might never execute). PR Close #54224 27 February 2024, 02:31:13 UTC
f578889 fix(compiler-cli): catch function instance properties in interpolated signal diagnostic (#54325) Currently, the following template compiles without error, even if the signal is not properly called: ``` <div>{{ mySignal.name }}</div> ``` This is because `name` is one of the instance properties of Function (see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function#instance_properties). The interpolated signal diagnostic is now extended to catch such issues. PR Close #54325 27 February 2024, 02:30:05 UTC
6842909 build: update scorecard action dependencies (#54407) See associated pull request for more information. PR Close #54407 27 February 2024, 02:29:36 UTC
12dc4d0 fix(compiler-cli): account for as expression in docs extraction (#54414) Fixes that the extraction for `object-literal-as-enum` didn't account for constants initialized to an `as` expression. PR Close #54414 27 February 2024, 02:29:09 UTC
9749589 feat(core): support TypeScript 5.4 (#54414) Adds support for TypeScript 5.4 to the project. PR Close #54414 27 February 2024, 02:29:09 UTC
a2a0067 build: update all non-major dependencies (#54510) See associated pull request for more information. PR Close #54510 27 February 2024, 02:28:44 UTC
1de9e19 docs: use components in model inputs guide (#54606) The code example showcases a `@Directive` with a template instead of a `@Component`. PR Close #54606 27 February 2024, 02:28:10 UTC
f5c566c fix(compiler-cli): identify aliased initializer functions (#54609) Fixes that initializer functions weren't being recognized if they are aliased (e.g. `import {model as alias} from '@angular/core';`). To do this efficiently, I had to introduce the `ImportedSymbolsTracker` which scans the top-level imports of a file and allows them to be checked quickly, without having to go through the type checker. It will be useful in the future when verifying that that initializer APIs aren't used in unexpected places. I've also introduced tests specifically for the `tryParseInitializerApiMember` function so that we can test it in isolation instead of going through the various functions that call into it. PR Close #54609 27 February 2024, 02:27:15 UTC
54b5a2f ci: correct @jeanmeche to @JeanMeche in pullapprove (#54610) Correct the casing so that it works as expected. PR Close #54610 26 February 2024, 18:25:08 UTC
69948e1 refactor(dev-infra): Import angular LS package in g3 (#54608) Import `angular/packages/language-service` in g3. We will still need to write BUILD files to get it building. PR Close #54608 26 February 2024, 17:04:33 UTC
d4343b5 Revert "fix(compiler-cli): identify aliased initializer functions (#54480)" (#54595) This reverts commit f04ecc0cdaeb3a292a748b1ccc94ce70a573fc79. PR Close #54595 26 February 2024, 16:36:49 UTC
dcb9deb fix(core): collect providers from NgModules while rendering `@defer` block (#52881) Currently, when a `@defer` block contains standalone components that import NgModules with providers, those providers are not available to components declared within the same NgModule. The problem is that the standalone injector is not created for the host component (that hosts this `@defer` block), since dependencies become defer-loaded, thus no information is available at host component creation time. This commit updates the logic to collect all providers from all NgModules used as a dependency for standalone components used within a `@defer` block. When an instance of a defer block is created, a new environment injector instance with those providers is created. Resolves #52876. PR Close #52881 23 February 2024, 20:30:05 UTC
0d95ae5 refactor(core): use performance API for signals (#54521) This commit adds a standard performance marker that can be viewed in Chrome dev tools and other tooling. See more info at https://developer.mozilla.org/en-US/docs/Web/API/Performance/mark PR Close #54521 23 February 2024, 20:18:30 UTC
4efcc74 docs: add a guide for model inputs (#54514) Adds a guide for `model()` inputs for angular.io. Will port this over to angular.dev once it's finalized. PR Close #54514 23 February 2024, 19:47:03 UTC
a3d5f7a docs: syntax error in signal input transform example (#54567) PR Close #54567 23 February 2024, 19:46:10 UTC
835c3a1 docs: Update wildcard route component to PageNotFoundComponent (#54570) This PR enhances the Angular documentation by replacing the placeholder `<component-name>` with the actual `PageNotFoundComponent` in the wildcard route configuration. This update ensures that the documentation accurately reflects the recommended practice for handling page-not-found scenarios. Additionally, it addresses the issue where HTML entities like `&lt;` were being displayed instead of the desired `<` symbol, resulting in clearer and more readable documentation for users. PR Close #54570 23 February 2024, 19:45:38 UTC
f04ecc0 fix(compiler-cli): identify aliased initializer functions (#54480) Fixes that initializer functions weren't being recognized if they are aliased (e.g. `import {model as alias} from '@angular/core';`). To do this efficiently, I had to introduce the `ImportedSymbolsTracker` which scans the top-level imports of a file and allows them to be checked quickly, without having to go through the type checker. It will be useful in the future when verifying that that initializer APIs aren't used in unexpected places. I've also introduced tests specifically for the `tryParseInitializerApiMember` function so that we can test it in isolation instead of going through the various functions that call into it. PR Close #54480 23 February 2024, 19:44:36 UTC
52924c5 docs: remove mutate function mention (#54569) PR Close #54569 23 February 2024, 19:43:24 UTC
35e5ba0 ci: adding Matthieu as approver for ADEV (#54575) This is to help the team approve changes on the new doc site. PR Close #54575 23 February 2024, 19:42:44 UTC
c5a7661 refactor(compiler-cli): changes to get signal diagnostic working internally (#54585) The diagnostic for signals that haven't been invoked wasn't working internally, because the path to `@angular/core` is different. These changes resolve the issue and do some general cleanup. PR Close #54585 23 February 2024, 19:42:04 UTC
71e0c7d fix(migrations): resolve infinite loop for a single line element with a long tag name and angle bracket on a new line (#54588) Fixes an edge case where a single-line elemnt with a long tag name a closing bracket on a new line was putting the control flow migration into an infinite loop. Fixes #54587. PR Close #54588 23 February 2024, 19:40:27 UTC
1a6beae feat(compiler): Enable template pipeline by default. (#54571) Template pipeline is now the default template compiler. A pair of source map tests is failing, related to DI in JIT mode; I will fix and re-enable these during the preview period. PR Close #54571 23 February 2024, 19:15:36 UTC
812a972 docs(docs-infra): revert font-inlining (#54573) To fix the CI/Build for ADEV. PR Close #54573 23 February 2024, 18:30:04 UTC
3f95829 refactor(core): Allow dirty views to be refreshed in a loop internally (#54572) ApplicationRef.tick has a loop that will refresh views again that have an updated signal. This change ensures views marked with the `Dirty` flag are also considered in this loop, but only inside g3 for now because this may be considered a breaking change and we need to wait for v18 to land externally. PR Close #54572 23 February 2024, 17:59:11 UTC
707bfc9 perf(common): `AsyncPipe` should not call `markForCheck` on subscription (#54554) This commit prevents `AsyncPipe` from calling `markForCheck` when values are synchronously emit during subscription to an observable. This prevents subscriptions to `Replay` observables from needlessly walking up to the root of the view tree during template execution for each new replay observable in the template. PR Close #54554 23 February 2024, 17:20:02 UTC
8e65bdc release: cut the v17.3.0-next.0 release 22 February 2024, 02:02:51 UTC
0971029 docs: release notes for the v17.2.2 release 22 February 2024, 01:57:34 UTC
f5f73fd docs(docs-infra): enable webcontainers for Firefox (#54550) PR Close #54550 21 February 2024, 23:27:36 UTC
e7b6be5 build: perform build/serve of adev locally (#54549) Use no-remote-exec to allow for building and serving to occur locally but still allow remote caching. Because of the number of files involved in being passed to and from the RBE server, it is actually a bit faster to perform these actions locally. PR Close #54549 21 February 2024, 23:27:02 UTC
42d3ddd fix(migrations): Fix cf migration regular expression to include underscores (#54533) In rare cases people may use an underscore in their component names, which was not accounted for in the formatting portion of the migration. fixes: #54532 PR Close #54533 21 February 2024, 23:25:05 UTC
9ec2224 docs(devtools): expand release docs (#54525) This provides some more information on how to release and notably includes commands for zipping extension code and source code, which can otherwise be tricky to get exactly right. PR Close #54525 21 February 2024, 23:24:26 UTC
back to top