-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Upgraded grunt and fixed amd importing of scripts
- Loading branch information
1 parent
dc27e36
commit 12575cd
Showing
6 changed files
with
131 additions
and
137 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,74 +1,58 @@ | ||
{ | ||
"predef": [ | ||
"jasmine", | ||
"spyOn", | ||
"it", | ||
"console", | ||
"describe", | ||
"expect", | ||
"beforeEach", | ||
"afterEach", | ||
"waits", | ||
"waitsFor", | ||
"runs", | ||
"$", | ||
"jQuery", | ||
"_", | ||
"require", | ||
"define", | ||
"sinon", | ||
"thumbs" | ||
"require" | ||
], | ||
|
||
"node" : true, | ||
"browser" : true, | ||
"devel" : true, | ||
"jquery" : true, | ||
"node": true, | ||
"browser": true, | ||
"devel": true, | ||
"jquery": true, | ||
|
||
"bitwise" : false, | ||
"camelcase" : true, | ||
"curly" : true, | ||
"eqeqeq" : true, | ||
"forin" : false, | ||
"immed" : true, | ||
"indent" : 4, | ||
"latedef" : true, | ||
"newcap" : true, | ||
"noarg" : true, | ||
"noempty" : true, | ||
"nonew" : false, | ||
"plusplus" : false, | ||
"quotmark" : false, | ||
"regexp" : false, | ||
"undef" : true, | ||
"unused" : false, | ||
"strict" : false, | ||
"trailing" : true, | ||
"white" : false, | ||
"bitwise": false, | ||
"camelcase": true, | ||
"curly": true, | ||
"eqeqeq": true, | ||
"forin": false, | ||
"immed": true, | ||
"indent": 4, | ||
"latedef": true, | ||
"newcap": true, | ||
"noarg": true, | ||
"noempty": true, | ||
"nonew": false, | ||
"plusplus": false, | ||
"quotmark": false, | ||
"regexp": false, | ||
"undef": true, | ||
"unused": false, | ||
"strict": false, | ||
"trailing": true, | ||
"white": false, | ||
|
||
"asi" : false, | ||
"boss" : false, | ||
"debug" : false, | ||
"eqnull" : true, | ||
"es5" : true, | ||
"esnext" : true, | ||
"evil" : false, | ||
"expr" : true, | ||
"funcscope" : false, | ||
"globalstrict" : false, | ||
"iterator" : false, | ||
"lastsemic" : false, | ||
"laxbreak" : false, | ||
"laxcomma" : false, | ||
"loopfunc" : false, | ||
"multistr" : false, | ||
"onecase" : false, | ||
"proto" : false, | ||
"regexdash" : false, | ||
"scripturl" : false, | ||
"smarttabs" : false, | ||
"shadow" : false, | ||
"sub" : true, | ||
"supernew" : true, | ||
"validthis" : false | ||
"asi": false, | ||
"boss": false, | ||
"debug": false, | ||
"eqnull": true, | ||
"es5": true, | ||
"esnext": true, | ||
"evil": false, | ||
"expr": true, | ||
"funcscope": false, | ||
"globalstrict": false, | ||
"iterator": false, | ||
"lastsemic": false, | ||
"laxbreak": false, | ||
"laxcomma": false, | ||
"loopfunc": false, | ||
"multistr": false, | ||
"onecase": false, | ||
"proto": false, | ||
"regexdash": false, | ||
"scripturl": false, | ||
"smarttabs": false, | ||
"shadow": false, | ||
"sub": true, | ||
"supernew": true, | ||
"validthis": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
/*global module:false*/ | ||
module.exports = function (grunt) { | ||
// Project configuration. | ||
grunt.initConfig({ | ||
pkg: grunt.file.readJSON('package.json'), | ||
|
||
jshint: { | ||
file: "./index.js", | ||
options: { | ||
jshintrc: '.jshintrc' | ||
} | ||
}, | ||
|
||
lint: { | ||
files: [ | ||
'array.js' | ||
] | ||
}, | ||
|
||
it: { | ||
all: { | ||
src: 'test/**/*.test.js', | ||
options: { | ||
timeout: 3000, // not fully supported yet | ||
reporter: 'dotmatrix' | ||
} | ||
} | ||
}, | ||
min: { | ||
dist: { | ||
src: ['<banner:meta.banner>', 'index.js'], | ||
dest: '<%= pkg.name %>.min.js' | ||
} | ||
}, | ||
watch: { | ||
files: '<config:lint.files>', | ||
tasks: 'lint it' | ||
}, | ||
uglify: { | ||
options: { | ||
banner: '/*! <%= pkg.name %> - v<%= pkg.version %> - ' + | ||
'<%= grunt.template.today("yyyy-mm-dd") %>\n' + | ||
'<%= pkg.homepage ? "* " + pkg.homepage + "\\n" : "" %>' + | ||
'* Copyright (c) <%= grunt.template.today("yyyy") %> <%= pkg.author %>;' + | ||
' Licensed <%= pkg.license %> */\n' | ||
}, | ||
min: { | ||
files: { | ||
'<%= pkg.name %>.min.js': ['index.js'] | ||
} | ||
} | ||
} | ||
}); | ||
|
||
// Default task. | ||
grunt.registerTask('default', ['jshint', 'it', 'uglify:min']); | ||
grunt.loadNpmTasks('grunt-it'); | ||
grunt.loadNpmTasks('grunt-contrib-jshint'); | ||
grunt.loadNpmTasks('grunt-contrib-uglify'); | ||
|
||
}; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.