backgrid-filter
Version:
Search box widget extension for Backgrid.js. Supports server-side, client-side and full-text searching.
95 lines (81 loc) • 1.85 kB
JavaScript
/*
backgrid-filter
http://github.com/wyuenho/backgrid-text-cell
Copyright (c) 2013 Jimmy Yuen Ho Wong and contributors
Licensed under the MIT license.
*/
// jshint globalstrict:true, node:true
"use strict";
module.exports = function (grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON("package.json"),
clean: {
options: {
force: true
},
api: [
"api/**/*"
],
"default": [
"*.min.*",
"test/coverage/**/*"
]
},
karma: {
unit: {
configFile: 'karma.conf.js',
singleRun: true
}
},
jsduck: {
main: {
src: ["backgrid-filter.js"],
dest: "api",
options: {
"title": "backgrid-filter",
"no-source": true,
"categories": "categories.json",
"warnings": "-no_doc",
"pretty-json": true
}
}
},
recess: {
csslint: {
options: {
compile: true
},
files: {
"backgrid-filter.css": ["backgrid-filter.css"]
}
},
"default": {
options: {
compress: true
},
files: {
"backgrid-filter.min.css": ["backgrid-filter.css"]
}
}
},
uglify: {
options: {
mangle: true,
compress: true,
preserveComments: "some"
},
"default": {
files: {
"backgrid-filter.min.js": ["backgrid-filter.js"]
}
}
}
});
grunt.loadNpmTasks("grunt-contrib-clean");
grunt.loadNpmTasks("grunt-contrib-uglify");
grunt.loadNpmTasks("grunt-recess");
grunt.loadNpmTasks("grunt-jsduck");
grunt.loadNpmTasks("grunt-karma");
grunt.registerTask("dist", ["uglify", "recess"]);
grunt.registerTask("default", ["clean", "jsduck", "dist", "karma"]);
};