693045165c
Up until this point, all static attribute values (things like `title` and `id`) defined within the `host` are of a Component/Directive definition were generated into a `def.attributes` array and then processed at runtime. This design decision does not lend itself well to tree-shaking and is inconsistent with other static values such as styles and classes. This fix ensures that all static attribute values (attributes, classes, and styles) that exist within a host definition for components and directives are all assigned via the `elementHostAttrs` instruction. ``` // before defineDirective({ ... attributes: ['title', 'my title'] ... }) //now defineDirective({ ... hostBindings: function() { if (create) { elementHostAttrs(..., ['title', 'my-title']); } ... } ... }) ``` PR Close #28089 |
||
---|---|---|
.. | ||
compliance | ||
diagnostics | ||
metadata | ||
ngcc | ||
ngtsc | ||
transformers | ||
BUILD.bazel | ||
extract_i18n_spec.ts | ||
mocks.ts | ||
ngc_spec.ts | ||
ngtools_api_spec.ts | ||
perform_compile_spec.ts | ||
perform_watch_spec.ts | ||
test_support.ts |