feat(ivy): setClassMetadata() for assigning decorator metadata (#26860)
This commit introduces the setClassMetadata() private function, which adds metadata to a type in a way that can be accessed via Angular's ReflectionCapabilities. Currently, it writes to static fields as if the metadata being added was downleveled from decorators by tsickle. The plan is for ngtsc to emit code which calls this function, passing metadata on to the runtime for testing purposes. Calls to this function would then be tree-shaken away for production bundles. Testing strategy: proper operation of this function will be an integral part of TestBed metadata overriding. Angular core tests will fail if this is broken. PR Close #26860
This commit is contained in:

committed by
Matias Niemelä

parent
afbee736ea
commit
ca1e538752
@ -43,6 +43,7 @@ const CORE_SUPPORTED_SYMBOLS = new Set<string>([
|
||||
'defineInjector',
|
||||
'ɵdefineNgModule',
|
||||
'inject',
|
||||
'ɵsetClassMetadata',
|
||||
'ɵInjectableDef',
|
||||
'ɵInjectorDef',
|
||||
'ɵNgModuleDefWithMeta',
|
||||
|
Reference in New Issue
Block a user