Skip to content

Added option to turn off JSHint for translations file #153

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Check the website for usage instructions: [http://angular-gettext.rocketeer.be/]

## Options

All options and defaults are displayed below:
All options and defaults are displayed below:

```JSON
{
Expand All @@ -33,11 +33,12 @@ All options and defaults are displayed below:
"lineNumbers": true,
"format": "javascript",
"defaultLanguage": false,
"requirejs": false
"requirejs": false,
"jshintIgnore": false
}
```

## License
## License

(The MIT License)

Expand Down
6 changes: 5 additions & 1 deletion lib/compile.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@ var formats = {
module += '}]);';

if (options.requirejs) {
return 'define([\'angular\', \'' + options.modulePath + '\'], function (angular) {\n' + module + '\n});';
module = 'define([\'angular\', \'' + options.modulePath + '\'], function (angular) {\n' + module + '\n});';
}

if (options.jshintIgnore) {
module = '// jshint ignore: start\n' + module;
}

return module;
Expand Down