grunt-i18n-static

0.1.16 • Public • Published

grunt-i18n-static

Grunt task for node-static-i18n. This will add a task i18n to your Grunt tasks.

Installation

$ npm install --save-dev grunt-i18n-static

Usage

Sample configuration:

module.exports = function (grunt) {
  grunt.initConfig({
    i18n: {
      dist: {
        options: {
          baseDir: 'www',
          outputDir: 'public',
        }
      },
      options: {
        fileFormat: 'yml',
        exclude: ['components/'],
        locales: ['en', 'fr'],
        locale: 'en',
        localesPath: 'locales'
      }
    }
  });
  grunt.loadNpmTasks('grunt-i18n-static');
};

with a project structure looking like this:

$ tree
.
├── Gruntfile.js
├── locales
│   ├── en.yml
│   └── fr.yml
├── package.json
└── www
    └── index.html

See node-static-i18n documentation for more information.

Package Sidebar

Install

npm i grunt-i18n-static

Weekly Downloads

47

Version

0.1.16

License

MIT

Unpacked Size

3.73 kB

Total Files

4

Last publish

Collaborators

  • danhper