Metadata Utilities
#
Metadata UtilitiesensureContentId
#
Ensure that a given RichContent
object contains an id by generating one (if not exist) or leaving it as is (if it does).
If no content is provided, an empty content with a new id is generated.
#
ExampleextractIdFromContent
#
For a given content, it will extract the id
from it. If not exists, undefined
will be returned.
#
ExamplecreateEmptyContent
#
Creates an empty, valid RichContent
object
#
Exampleduplicate
#
Duplicates a RichContent
object, with a newly generated id
.