Ngx meta.makemetadatamanagerproviderfromsetterfactory
Home > @davidlj95/ngx-meta > makeMetadataManagerProviderFromSetterFactory
makeMetadataManagerProviderFromSetterFactory() function
Warning: This API is now obsolete.
Use provideNgxMetaManager() APIs instead. See custom metadata guide for more information.
Creates an Angular factory provider providing an NgxMetaMetadataManager.
See manage custom metadata guide for an example.
Signature:
makeMetadataManagerProviderFromSetterFactory: <T>(setterFactory: MetadataSetterFactory<T>, opts: MakeMetadataManagerProviderFromSetterFactoryOptions) => FactoryProvider
Parameters
Parameter | Type | Description |
---|---|---|
setterFactory | MetadataSetterFactory<T> | Function that creates a NgxMetaMetadataManager given some dependencies |
opts | MakeMetadataManagerProviderFromSetterFactoryOptions | Options to create the factory |
Returns:
FactoryProvider
Remarks
Factory providers are used for built-in modules instead of Angular services. Reason is that code created by @Injectable
decorator takes many bytes, whereas a call to this function creating a factory provider takes fewer.