File: gettext.info, Node: JavaScript, Next: TypeScript, Prev: C#, Up: List of Programming Languages 16.5.5 JavaScript ----------------- RPMs js Ubuntu packages gjs File extension ‘js’ String syntax • ‘"abc"’ • ‘'abc'’ • ‘`abc`’ • ‘TAG`abc${EXPRESSION}def{EXPRESSION}...`’, see the description of ‘--tag’ in *note xgettext Invocation::. gettext shorthand ‘_("abc")’ gettext/ngettext functions ‘gettext’, ‘dgettext’, ‘dcgettext’, ‘ngettext’, ‘dngettext’ textdomain ‘textdomain’ function bindtextdomain ‘bindtextdomain’ function setlocale automatic Prerequisite -- Use or emulate GNU gettext use, or emulate Extractor ‘xgettext’ Formatting with positions A ‘format’ method on strings can be used. But since it is not standard in JavaScript, you have to enable it yourself, through const Format = imports.format; String.prototype.format = Format.format; Portability On platforms without gettext, the functions are not available. po-mode marking --
