Coder Social home page Coder Social logo

gulp-angular-translate's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

gulp-angular-translate's Issues

Version 0.1.3 does not work in Windows

In the source code: file.path.split('/')

This does not work in Windows where \\ is used as the path separator. Maybe using something like this: file.path.replace(/\\/g, '/').split('/')

Module throws an error when attempting to load files with different names then expected ( like "tkey.json" )

Steps to reproduce:

  1. Create a gulp task.
  2. Create a JSON file with "tkey.json" name and save it.
  3. Point gulp.src at the file's location.
  4. Do not add any "options.language" configuration.
  5. Run the gulp task.
  6. Notice console.

Result:

Running the task will output an error:

TypeError: Cannot read property 'pop' of null
at <DIRECTORY PATH ...>\node_modules\gulp-angular-translate\index.js:11:130
.......

Additional notes:

Reported the bug in case others encounter the issue.

translations.js doesn't update string value

Hey,

I am facing a weird case, I am running the task to concat all the strings and a translations.js file, but for some reason when I update a string the value in translations.js still the old one, I have tried to delete the file with "del" without success.

When I change some value and concat again with task the values are updated.

It seems a kind of cache, any idea about this ?

Error: Cannot find module 'gulp-util'

Error: Cannot find module 'gulp-util'
    at Function.Module._resolveFilename (module.js:338:15)
    at Function.Module._load (module.js:280:25)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)
    at Object.<anonymous> (/home/repos/esl-html-mobile/node_modules/gulp-angular-translate/index.js:3:13)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Module.require (module.js:364:17)

When installing through npm, the package.json is missing gulp-util as a dependency. The gulp task doesn't work without it.

When I add the dependency and run npm install again, it works.

"dependencies": {
    "event-stream": "3.1.7",
    "gulp-concat": "2.4.2",
    "gulp-util": "3.0.1"
  }

Make concatinating files optional

Could the concatination of the files be made optional? I'd like one angular-module-file for each language.

Example:

translation-en-US.json ==> translation-en-US.js
translation-de-DE.json ==> translation-de-DE.js

regex for file matching is restrictive

Your assumption that the naming translation files adhere to your standard is too restrictive.
You should allow "*/.json" to be globbed.
Want me to make a pull request?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.