angular-cn/goldens/public-api
JoostK 51156f3f07 fix(core): allow proper type inference when `ngFor` is used with a `trackBy` function (#42692)
In #41995 the type of `TrackByFunction` was changed such that the
declaration of a `trackBy` function did not cause the item type to be
widened to the `trackBy`'s item type, which may be a supertype of the
iterated type. This has introduced situations where the template type
checker is now reporting errors for cases where a `trackBy` function is
no longer assignable to `TrackByFunction`.

This commit fixes the error by also including the item type `T` in
addition to the constrained type parameter `U`, allowing TypeScript to
infer an appropriate `T`.

Fixes #42609

PR Close #42692
2021-07-13 14:08:05 -07:00
..
animations build: update API goldens after api-extractor update (#42737) 2021-07-02 10:08:03 -07:00
common build: update API goldens after api-extractor update (#42737) 2021-07-02 10:08:03 -07:00
compiler-cli fix(compiler-cli): check split two way binding (#42601) 2021-07-13 08:47:11 -07:00
core fix(core): allow proper type inference when `ngFor` is used with a `trackBy` function (#42692) 2021-07-13 14:08:05 -07:00
elements build: update API goldens to reflect new tool (#42688) 2021-06-30 11:43:48 -07:00
forms build: update API goldens to reflect new tool (#42688) 2021-06-30 11:43:48 -07:00
localize build: update API goldens after api-extractor update (#42737) 2021-07-02 10:08:03 -07:00
platform-browser build: update API goldens to reflect new tool (#42688) 2021-06-30 11:43:48 -07:00
platform-browser-dynamic build: update API goldens to reflect new tool (#42688) 2021-06-30 11:43:48 -07:00
platform-server build: update API goldens to reflect new tool (#42688) 2021-06-30 11:43:48 -07:00
router build: update API goldens after api-extractor update (#42737) 2021-07-02 10:08:03 -07:00
service-worker build: update API goldens after api-extractor update (#42737) 2021-07-02 10:08:03 -07:00
upgrade build: update API goldens to reflect new tool (#42688) 2021-06-30 11:43:48 -07:00
manage.js ci: move public-api goldens to goldens directory (#35768) 2020-03-10 20:58:39 -04:00