Embed
No summary available
import { Embed } from "@schukai/monster/source/i18n/providers/embed.mjs";Exported
EmbedDerived from
ProviderOptions
The Options listed in this section are defined directly within the class. This class is derived from several parent classes. Therefore, it inherits Options from these parent classes. If you cannot find a specific Options in this list, we recommend consulting the documentation of the Provider.
Properties
The Properties listed in this section are defined directly within the class. This class is derived from several parent classes. Therefore, it inherits Properties from these parent classes. If you cannot find a specific Properties in this list, we recommend consulting the documentation of the Provider.
Methods
The methods listed in this section are defined directly within the class. This class is derived from several parent classes. Therefore, it inherits methods from these parent classes. If you cannot find a specific method in this list, we recommend consulting the documentation of the Provider.
Constructor
constructor(elementOrId,options)elementOrId{htmlelement|string}: elementOrIdoptions{object}: options
<script id="translations" type="application/json">
{ "hello": "Hallo" }
</script>
new Embed("translations");
Structural methods
getTranslations(locale)locale{locale|string}: locale
- {Promise}
Static methods
assignTranslationsToElement(element)element: element
script[data-monster-role=translations] is searched for and the translations are assigned to the element.Events
This component does not fire any public events. It may fire events that are inherited from its parent classes.