Localizing Labels in Custom HTML Using Pendo
Hi!
Is there a way to localize labels inside custom HTML using Pendo's capabilities?
I imagine that if such functionality exists, we could use attributes like
<span data-pendo-id="key-xxx">Some text</span>
on spans/divs/etc., and then export the texts via the standard translation export feature — similar to how it currently works for non-custom HTML components.
Is this supported?
If not, one possible workaround would be to pass keys with values via metadata and apply translations using custom JS. But I'm hoping something like this might already be available.
Refactoring the custom HTML to use standard Pendo controls isn't an option right now, since we're using non-standard UI components.
0
コメント
I wanted to share a small solution I put together for localizing Pendo guides when using code blocks with custom HTML and JavaScript.
It uses
data-translate-idattributes in the HTML and a simple translation map in JavaScript. The script picks up the user’s language fromlocalStorage(i18nextLng) and replaces the text accordingly. This approach could be helpful for anyone managing multi-language guides manually in code.Here’s a simplified example you can copy and adapt:
HTML
JS
サインインしてコメントを残してください。