1.2.2 • Published 8 years ago

csv-locales v1.2.2

Weekly downloads
5
License
MIT
Repository
github
Last release
8 years ago

csv-locales

This module creates json files with i18n locales for Google Chrome extensions and applications from a CSV file.

Installation

npm install --save csv-locales

Usage

To create locales use a CSV file which generated from a spreadsheet with this structure.

You can use it as a grunt task or as a gulp task, or as in example below:

var csvLocales = require('csv-locales');

var params = {
  csvPath: 'path/to/the/file/locales.csv',
  dirPath: 'path/to/the/target/dir/_locales',
  csvParse: {/* CSV parser option or null */}
};

csvLocales(params, function (err) {
  if (err) {
    throw err;
  }
  
  // All done!
});

Params available

  • csvPath - a path to the CSV file with locales.
  • dirPath - a path to the target directory. If it doesn't exist, it will be created.
  • csvParse — a list of options for the CSV parser.

License

MIT

1.2.2

8 years ago

1.2.1

8 years ago

1.2.0

9 years ago

1.1.1

9 years ago

1.1.0

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago