Socket
Book a DemoInstallSign in
Socket

i18n-message

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

i18n-message

Converting message.properties into json object

1.0.1
latest
Source
npmnpm
Version published
Weekly downloads
1
-80%
Maintainers
1
Weekly downloads
 
Created
Source

i18n-message

Build Status

Node.js module for processing .strings/.properties files used for localization

Installing with npm

npm install i18n-message

Usage

i18n-message can be used to read a .properties file and parse it into an object.

Note that specifying an encoding is optional. If an encoding is not specified, UTF-16 will be used as recommended by Apple. It's important to understand the encoding of the file being read/written and make sure it's specified properly (if it's something other than UTF-16).

#sample properties file
default.username.label = Username
// Include i18n-strings-files
const i18n = require('i18n-message');
const message = i18n('i18n/message.properties')
console.log(message.default.username.label);
// output: Username

Keywords

i18n

FAQs

Package last updated on 22 Oct 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.