Skip to content

vinay3206/gulp-ember-autolocalization

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gulp-ember-autolocalization

This is a gulp plugin to process to add localization helper to handlebars template.

Usage

First, install gulp-ember-autolocalization:

npm install gulp-ember-autolocalization

Then, add it to your gulpfile.js and pass localization helper name to function:

var autoLocalization = require('gulp-ember-autolocalization');

gulp.task('templates', function(){
  gulp.src(['client/templates/*.hbs'])
    .pipe(autoLocalization('loc'))
    .pipe(gulp.dest('build/templates/'));
});

gulp-auto-localization outputs a raw Ember.Handlebars.template with localization helper added to text

helperName

Type: String

Specify your helper name while calling the function. Default value loc will be taken if nothing is passed.

##Example input

<div>hello {{isHello}}</div>

##Example output Assuming helper passes is loc

<div>{{loc 'hello'}} {{isHello}}</div>

About

this is gulp plugin which will add ember js localization helper to your Handlebars templates

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published