traduire_options | R Documentation |
Takes a named set of options and optionally an already created options object. If both are set, named options will overwrite any options in the object.
traduire_options(..., options = NULL)
... |
Named options language The default language for the translation default_namespace The default namespace to use. If not
given, then debug Logical, indicating if i18next's debug output should
be turned on. This will result in lots of output via
resource_pattern A pattern to use for on-demand loading of
translation resources. Only works if namespaces A vector of namespaces to load. Namespaces not
listed here may not be loaded as expected (use languages A vector of languages to preload. You can
always add additional languages using the fallback The fallback language to use. The options here
are to use a character string (a single fallback to use for all
languages), a character vector (a series of languages to use in
turn, listed from first to try to last to try) or a named list
of language-fallback mappings, e.g., escape Logical, indicating if the translation output should be, by default, escaped (see the i18next interpolation documentation). The i18next implementation is to prevent xss attacks, and so is disabled by default in traduire. |
options |
traduire_options object |
These options are passed to i18next.
A 'traduire_options' object
opts <- traduire::traduire_options()
opts <- traduire::traduire_options(language = "fr")
opts <- traduire::traduire_options(default_namespace = "tr", options = opts)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.