Skip to content

Ngx meta.makekeyvalmetadefinition

Home > @davidlj95/ngx-meta > makeKeyValMetaDefinition

makeKeyValMetaDefinition() function

Warning: This API is now obsolete.

Use NgxMetaElementsService APIs instead. See custom metadata guide for more info

Creates a NgxMetaMetaDefinition for its use with NgxMetaMetaService by understanding <meta> elements as key / value pair elements.

Signature:

makeKeyValMetaDefinition: (keyName: string, options?: MakeKeyValMetaDefinitionOptions) => NgxMetaMetaDefinition

Parameters

Parameter Type Description
keyName string Name of the key in the key/value meta definition
options MakeKeyValMetaDefinitionOptions (Optional) Specifies HTML attribute names and extras of the definition if any

Returns:

NgxMetaMetaDefinition

Remarks

One can think about some <meta> elements as key / value pairs.

For instance <meta name='description' content='Lorem ipsum'> would actually be a key / value pair meta where - description is the key - Lorem ipsum is the value - name is the key's HTML attribute name - contentis the value's HTML attribute name

Value is set by NgxMetaMetaService.set() by providing this model and an actual value