i18n-slim
v0.2.1
Published
i18n library
Maintainers
Readme
i18now
- yaml format
- i18n attribute
- language default
<!DOCTYPE html>
<html lang="en">
<head>
<title>i18n</title>
<script src='i18now.js' />
</head>
<body>
<p i18n='title'>Welcome</p>
<p i18n>Hello world!</p>
</body>
</html>title: "Bem vindo"
"Hello world": "olá mundo!"title: "Bienvenue"
"Hello world": "Bonjour le monde!"title: "Willkommen"
"Hello world": "Hallo welt!"With i18n global object handles the language.
<script>
i18n.load('./languages')
i18h.lang = 'pt' // set language
i18n.lang // get language
</script>