Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on May 3, 2024 via pnpm

i18n 0.15.1

lightweight translation module with dynamic json storage
Package summary
Share
1
issue
1
high severity
license
1
4
licenses
11
MIT
2
BSD-3-Clause
1
Unicode-DFS-2016
1
ISC
Package created
25 Mar 2011
Version published
22 Sep 2022
Maintainers
1
Total deps
15
Direct deps
6
License
MIT

Issues

1

1 high severity issue

high
Recommendation: Read and validate the license terms
via: @messageformat/core@3.3.0 & others
Collapse
Expand

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
11 Packages, Including:
@messageformat/core@3.3.0
@messageformat/date-skeleton@1.0.1
@messageformat/number-skeleton@1.2.0
@messageformat/parser@5.1.0
@messageformat/runtime@3.0.1
boolean@3.2.0
debug@4.3.4
i18n@0.15.1
math-interval-parser@2.0.1
ms@2.1.2
mustache@4.2.0

BSD 3-Clause "New" or "Revised" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
use-trademark
hold-liable
Must
include-copyright
include-license
2 Packages, Including:
fast-printf@1.6.9
moo@0.5.2

Unicode License Agreement - Data Files and Software (2016)

Uncategorized
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
Cannot
Must
1 Packages, Including:
make-plural@7.4.0

ISC License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
safe-identifier@0.4.2
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

6
All Dependencies CSV
β“˜ This is a list of i18n 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
@messageformat/core3.3.059.83 kBMIT
prod
1
debug4.3.412.94 kBMIT
prod
fast-printf1.6.96.44 kBBSD-3-Clause
prod
make-plural7.4.0359 kBUnicode-DFS-2016
prod
1
math-interval-parser2.0.12.88 kBMIT
prod
mustache4.2.033.77 kBMIT
prod

Visualizations

Frequently Asked Questions

What does i18n do?

i18n is a lightweight translation module with dynamic JSON storage. It is designed to work with plain vanilla Node.js applications and just about any Node.js framework, such as Express or Restify. Its main function is to facilitate smooth and efficient language translations within your JavaScript codebase, which is critical in the creation of multi-language applications. The i18n package uses a common __('...') syntax in apps and templates, and dynamically adds new strings to your language file.json when first used in your application.

How do you use i18n?

To use i18n, first, install it with npm install i18n --save. Here's an example of how to wire up this package using the Node.js HTTP module:

const http = require('http')
const path = require('path')
const { I18n } = require('i18n')

const i18n = new I18n({
  locales: ['en', 'de'],
  directory: path.join(__dirname, 'locales')
})

const app = http.createServer((req, res) => {
  i18n.init(req, res)
  res.end(res.__('Hello'))
})

app.listen(3000, '127.0.0.1')

In the above example, based on the browser's 'Accept-Language', the server will return "Hello" in either English ('en') or German ('de'). There are also examples showing usage as an instance or singleton, and many other configuration options are available to fit different requirements.

Where are the i18n docs?

In terms of documentation, all documentation for i18n is available directly in the README file at the GitHub project page for the i18n Node.js package. The URL