angular/packages/compiler
Kristiyan Kostadinov 9e847fc60d fix(compiler): handle tracking expressions requiring temporary variables (#58520)
Currently when we generate the tracking expression for a `@for` block, we process its expression in the context of the creation block. This is incorrect, because the expression may require ops of its own for cases like nullish coalescing or safe reads. The result is that while we do generate the correct variable, they're added to the creation block rather than the tracking function which causes an error at runtime.

These changes address the issue by keeping track of a separate set of ops for the `track` expression that are prepended to the generated function, similarly to how we handle event listeners.

Fixes #56256.

PR Close #58520
2025-02-12 09:56:08 -08:00
..
design docs: capitalize webpack with a lowercase W (#56812) 2024-11-26 22:24:11 +00:00
src fix(compiler): handle tracking expressions requiring temporary variables (#58520) 2025-02-12 09:56:08 -08:00
test refactor(compiler): produce AST for template literals (#59230) 2025-01-21 12:04:52 -08:00
BUILD.bazel refactor(platform-server): Add an ssr benchmark setup. (#57647) 2024-10-04 10:45:22 -07:00
compiler.ts refactor: update license text to point to angular.dev (#57901) 2024-09-24 15:33:00 +02:00
index.ts refactor: update license text to point to angular.dev (#57901) 2024-09-24 15:33:00 +02:00
package.json build: update Node.js to match Angular CLI engines (#56187) 2024-06-03 18:00:46 +00:00
public_api.ts refactor: update license text to point to angular.dev (#57901) 2024-09-24 15:33:00 +02:00