mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-23 11:55:01 +03:00
Move jshint logic out of Gruntfile.js and into .jshintrc files
This commit is contained in:
parent
beb078b52c
commit
a0ba5cb1b1
26
.jshintrc
Normal file
26
.jshintrc
Normal file
@ -0,0 +1,26 @@
|
||||
{
|
||||
"node": true,
|
||||
"browser": false,
|
||||
"nomen": false,
|
||||
"strict": false,
|
||||
"sub": true,
|
||||
"eqeqeq": true,
|
||||
"laxbreak": true,
|
||||
"bitwise": true,
|
||||
"curly": true,
|
||||
"forin": true,
|
||||
"immed": true,
|
||||
"latedef": true,
|
||||
"newcap": true,
|
||||
"noarg": true,
|
||||
"noempty": true,
|
||||
"nonew": true,
|
||||
"plusplus": true,
|
||||
"regexp": true,
|
||||
"undef": true,
|
||||
"unused": true,
|
||||
"trailing": true,
|
||||
"indent": 4,
|
||||
"onevar": true,
|
||||
"white": true
|
||||
}
|
62
Gruntfile.js
62
Gruntfile.js
@ -129,30 +129,7 @@ var path = require('path'),
|
||||
// Linting rules for server side or shared javascript code
|
||||
server: {
|
||||
options: {
|
||||
node: true,
|
||||
browser: false,
|
||||
nomen: false,
|
||||
strict: false,
|
||||
sub: true,
|
||||
eqeqeq: true,
|
||||
laxbreak: true,
|
||||
bitwise: true,
|
||||
curly: true,
|
||||
forin: true,
|
||||
immed: true,
|
||||
latedef: true,
|
||||
newcap: true,
|
||||
noarg: true,
|
||||
noempty: true,
|
||||
nonew: true,
|
||||
plusplus: true,
|
||||
regexp: true,
|
||||
undef: true,
|
||||
unused: true,
|
||||
trailing: true,
|
||||
indent: 4,
|
||||
onevar: true,
|
||||
white: true
|
||||
jshintrc: '.jshintrc'
|
||||
},
|
||||
files: {
|
||||
src: [
|
||||
@ -168,40 +145,7 @@ var path = require('path'),
|
||||
// Linting rules for client side javascript code
|
||||
client: {
|
||||
options: {
|
||||
predef: {
|
||||
document: true,
|
||||
window: true,
|
||||
location: true,
|
||||
setTimeout: true,
|
||||
Ember: true,
|
||||
Em: true,
|
||||
DS: true,
|
||||
$: true,
|
||||
validator: true,
|
||||
ic: true
|
||||
},
|
||||
node: false,
|
||||
browser: true,
|
||||
nomen: false,
|
||||
bitwise: true,
|
||||
curly: true,
|
||||
eqeqeq: true,
|
||||
forin: true,
|
||||
immed: true,
|
||||
latedef: true,
|
||||
newcap: true,
|
||||
noarg: true,
|
||||
noempty: true,
|
||||
nonew: true,
|
||||
plusplus: true,
|
||||
regexp: true,
|
||||
undef: true,
|
||||
unused: true,
|
||||
trailing: true,
|
||||
indent: 4,
|
||||
esnext: true,
|
||||
onevar: true,
|
||||
white: true
|
||||
jshintrc: 'core/client/.jshintrc'
|
||||
},
|
||||
files: {
|
||||
src: [
|
||||
@ -948,4 +892,4 @@ var path = require('path'),
|
||||
};
|
||||
|
||||
// Export the configuration
|
||||
module.exports = configureGrunt;
|
||||
module.exports = configureGrunt;
|
||||
|
32
core/client/.jshintrc
Normal file
32
core/client/.jshintrc
Normal file
@ -0,0 +1,32 @@
|
||||
{
|
||||
"node": false,
|
||||
"browser": true,
|
||||
"nomen": false,
|
||||
"bitwise": true,
|
||||
"curly": true,
|
||||
"eqeqeq": true,
|
||||
"forin": true,
|
||||
"immed": true,
|
||||
"latedef": true,
|
||||
"newcap": true,
|
||||
"noarg": true,
|
||||
"noempty": true,
|
||||
"nonew": true,
|
||||
"plusplus": true,
|
||||
"regexp": true,
|
||||
"undef": true,
|
||||
"unused": true,
|
||||
"trailing": true,
|
||||
"indent": 4,
|
||||
"esnext": true,
|
||||
"onevar": true,
|
||||
"white": true,
|
||||
"globals": {
|
||||
"Ember": true,
|
||||
"Em": true,
|
||||
"DS": true,
|
||||
"$": true,
|
||||
"validator": true,
|
||||
"ic": true
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user