npm

Does your artifact manager get in the way? Join us on Oct. 8 at 10am PT, to discuss how npm can help.Sign up »

angular-tiny-translate

1.1.1 • Public • Published

npm npm Dependency Status devDependency Status

angular-tiny-translate

install

npm install angular-tiny-translate -S

Small modular library for translations without unused dust

angular
  .module('my.app', [
    'angular-tiny-translate'
  ])
 
  /*@ngInject*/
  .config((TinyTranslate) => {
    TinyTranslate.translates({
      'some_prefix1': {
        'some_key1': 'some_translation1'
      },
      'some_prefix2': {
        'some_key2': 'some_translation2',
        '*': '{*} times'
      }
    })  
  })
  <!-- someVar = 'some_key2' -->
  <h1>{{ someVar | tr: 'some_prefix2' }}</h1>
  <!-- result -->
  <h1>some_translation2</h1>
  <!-- someVar = '5' -->
  <h1>{{ someVar | tr: 'some_prefix2' }}</h1>
  <!-- result -->
  <h1>5 times</h1>

install

npm i angular-tiny-translate

Downloadsweekly downloads

10

version

1.1.1

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability