new Metadata(config) → {Spyral.Metadata}
The metadata constructor.
Parameters:
Name | Type | Description | ||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
config |
Object | The metadata config object Properties
|
Returns:
Spyral.MetadataMethods
-
clone() → {Spyral.Metadata}
-
Returns a clone of this Metadata
Returns:
Spyral.Metadata -
getHeaders() → {String}
-
Gets the fields as a set of HTML meta tags.
Returns:
String -
set(config)
-
Set metadata properties.
Parameters:
Name Type Description config
Object A config object
-
setDateNow(field)
-
Sets the specified field to the current date and time.
Parameters:
Name Type Description field
String -
shortDate(field) → {String|undefined}
-
Gets the specified field as a short date.
Parameters:
Name Type Description field
String Returns:
String | undefined