1.0.1 • Published 2 years ago

@inventivetalent/hi18n v1.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

hi18n

HTML internationalization

Uses the HTML tag's original text content as keys for loading translations from json files.

npm i @inventivetalent/hi18n

Demo: https://inventivetalent.org/hi18n-test/

<html>
    <body>
        <div>
            <span class="hi18n">Fowl stars lights dry green whales stars from signs.</span>
            <span class="hi18n">Be every his give grass dry fifth.</span>
            <span class="hi18n">Fly moving.</span>
            <span class="hi18n">May their made so lights darkness years.</span>
            <span class="hi18n">So gathering may from.</span>
            <span class="hi18n">Void signs man fowl fish moving.</span>
        </div>
        
        <script src="https://unpkg.com/@inventivetalent/hi18n@1.0.1/dist/bundle.js"></script>
        <script>
            new hi18n({
                auto: true // automatically translate on page load
            });
        </script>
    </body>
</html>