mirror of https://github.com/ColorlibHQ/AdminLTE
Add Search plugin to babel compiler and reformat code style
parent
97dfbaa79f
commit
8781ae4854
|
@ -5,16 +5,17 @@ module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
sourceMap: true,
|
sourceMap: true,
|
||||||
presets: ['es2015']
|
presets : ['es2015']
|
||||||
},
|
},
|
||||||
dist: {
|
dist : {
|
||||||
files: {
|
files: {
|
||||||
'build/js/dist/Layout.js': 'build/js/src/Layout.js',
|
'build/js/dist/Layout.js' : 'build/js/src/Layout.js',
|
||||||
'build/js/dist/Treeview.js': 'build/js/src/Treeview.js',
|
'build/js/dist/Treeview.js' : 'build/js/src/Treeview.js',
|
||||||
'build/js/dist/PushMenu.js': 'build/js/src/PushMenu.js',
|
'build/js/dist/PushMenu.js' : 'build/js/src/PushMenu.js',
|
||||||
'build/js/dist/Widget.js': 'build/js/src/Widget.js',
|
'build/js/dist/Widget.js' : 'build/js/src/Widget.js',
|
||||||
'build/js/dist/ControlSidebar.js': 'build/js/src/ControlSidebar.js',
|
'build/js/dist/ControlSidebar.js': 'build/js/src/ControlSidebar.js',
|
||||||
'dist/js/adminlte.js': 'build/js/src/AdminLTE.js'
|
'build/js/dist/Search.js' : 'build/js/src/Search.js',
|
||||||
|
'dist/js/adminlte.js' : 'build/js/src/AdminLTE.js'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -2,11 +2,11 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
relaxerror: ['W005']
|
relaxerror: ['W005']
|
||||||
},
|
},
|
||||||
// files: ['pages/**/*.html', '*.html']
|
// files: ['pages/**/*.html', '*.html']
|
||||||
files: ['starter.html']
|
files : ['starter.html']
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,17 +3,18 @@
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options : {
|
||||||
stripBanners: true,
|
stripBanners: true,
|
||||||
banner: '<%= banner %>'
|
banner : '<%= banner %>'
|
||||||
},
|
},
|
||||||
adminlte: {
|
adminlte: {
|
||||||
src: [
|
src : [
|
||||||
'build/js/src/Layout.js',
|
'build/js/src/Layout.js',
|
||||||
'build/js/src/Treeview.js',
|
'build/js/src/Treeview.js',
|
||||||
'build/js/src/PushMenu.js',
|
'build/js/src/PushMenu.js',
|
||||||
'build/js/src/Widget.js',
|
'build/js/src/Widget.js',
|
||||||
'build/js/src/ControlSidebar.js'
|
'build/js/src/ControlSidebar.js',
|
||||||
|
'build/js/src/Search.js'
|
||||||
],
|
],
|
||||||
dest: 'build/js/src/AdminLTE.js'
|
dest: 'build/js/src/AdminLTE.js'
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,11 +2,11 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
csslintrc: 'build/less/.csslintrc'
|
csslintrc: 'build/less/.csslintrc'
|
||||||
},
|
},
|
||||||
dist: [
|
dist : [
|
||||||
'dist/css/AdminLTE.css',
|
'dist/css/AdminLTE.css',
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
configFile: 'build/js/.eslintrc'
|
configFile: 'build/js/.eslintrc'
|
||||||
},
|
},
|
||||||
target: 'build/js/src/*.js'
|
target : 'build/js/src/*.js'
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
dynamic: {
|
dynamic: {
|
||||||
files: [{
|
files: [{
|
||||||
expand: true,
|
expand: true,
|
||||||
cwd: 'build/img/',
|
cwd : 'build/img/',
|
||||||
src: ['**/*.{png,jpg,gif,svg,jpeg}'],
|
src : ['**/*.{png,jpg,gif,svg,jpeg}'],
|
||||||
dest: 'dist/img/'
|
dest : 'dist/img/'
|
||||||
}]
|
}]
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -4,12 +4,12 @@
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
build: {
|
build: {
|
||||||
src: ['*.html'], // Source files
|
src : ['*.html'], // Source files
|
||||||
dest: 'documentation/', // Destination directory
|
dest : 'documentation/', // Destination directory
|
||||||
flatten: true,
|
flatten: true,
|
||||||
cwd: 'documentation/build',
|
cwd : 'documentation/build',
|
||||||
options: {
|
options: {
|
||||||
silent: true,
|
silent : true,
|
||||||
includePath: 'documentation/build/include'
|
includePath: 'documentation/build/include'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,14 +2,14 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
config: 'build/js/.jscsrc'
|
config: 'build/js/.jscsrc'
|
||||||
},
|
},
|
||||||
grunt: {
|
grunt : {
|
||||||
src: ['Gruntfile.js']
|
src: ['Gruntfile.js']
|
||||||
},
|
},
|
||||||
core: {
|
core : {
|
||||||
src: 'js/src/*.js'
|
src: 'js/src/*.js'
|
||||||
}
|
}
|
||||||
/*app: {
|
/*app: {
|
||||||
|
|
|
@ -2,17 +2,17 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
jshintrc: '.jshintrc'
|
jshintrc: '.jshintrc'
|
||||||
},
|
},
|
||||||
core: {
|
core : {
|
||||||
src: 'dist/js/app.js'
|
src: 'dist/js/app.js'
|
||||||
},
|
},
|
||||||
demo: {
|
demo : {
|
||||||
src: 'dist/js/demo.js'
|
src: 'dist/js/demo.js'
|
||||||
},
|
},
|
||||||
pages: {
|
pages : {
|
||||||
src: 'dist/js/pages/*.js'
|
src: 'dist/js/pages/*.js'
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -5,7 +5,7 @@ module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
watch: {
|
watch: {
|
||||||
options: {
|
options: {
|
||||||
title: 'Task Complete', // optional
|
title : 'Task Complete', // optional
|
||||||
message: 'SASS and Uglify finished running', //required
|
message: 'SASS and Uglify finished running', //required
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,26 +4,26 @@
|
||||||
|
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
development: {
|
development: {
|
||||||
options: {
|
options: {
|
||||||
precision: 6,
|
precision : 6,
|
||||||
sourceComments: false,
|
sourceComments: false,
|
||||||
sourceMap: true,
|
sourceMap : true,
|
||||||
outputStyle: 'expanded'
|
outputStyle : 'expanded'
|
||||||
},
|
|
||||||
files: {
|
|
||||||
'dist/css/adminlte.css': 'build/scss/AdminLTE.scss'
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
production: {
|
files : {
|
||||||
options: {
|
'dist/css/adminlte.css': 'build/scss/AdminLTE.scss'
|
||||||
sourceComments: false,
|
|
||||||
sourceMap: true,
|
|
||||||
outputStyle: 'compressed'
|
|
||||||
},
|
|
||||||
files: {
|
|
||||||
'dist/css/adminlte.min.css': 'build/scss/AdminLTE.scss'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
};
|
},
|
||||||
|
production : {
|
||||||
|
options: {
|
||||||
|
sourceComments: false,
|
||||||
|
sourceMap : true,
|
||||||
|
outputStyle : 'compressed'
|
||||||
|
},
|
||||||
|
files : {
|
||||||
|
'dist/css/adminlte.min.css': 'build/scss/AdminLTE.scss'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -4,13 +4,13 @@
|
||||||
module.exports = function (grunt) {
|
module.exports = function (grunt) {
|
||||||
return {
|
return {
|
||||||
options: {
|
options: {
|
||||||
mangle: true,
|
mangle : true,
|
||||||
preserveComments: 'some'
|
preserveComments: 'some'
|
||||||
},
|
},
|
||||||
target: {
|
target : {
|
||||||
files: {
|
files: {
|
||||||
'dist/js/adminlte.min.js': ['dist/js/adminlte.js'],
|
'dist/js/adminlte.min.js': ['dist/js/adminlte.js'],
|
||||||
'dist/js/app.min.js': ['dist/js/app.js']
|
'dist/js/app.min.js' : ['dist/js/app.js']
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -7,11 +7,11 @@ module.exports = function (grunt) {
|
||||||
files: ['build/scss/*.scss', 'build/scss/skins/*.scss'],
|
files: ['build/scss/*.scss', 'build/scss/skins/*.scss'],
|
||||||
tasks: ['sass', 'notify:watch']
|
tasks: ['sass', 'notify:watch']
|
||||||
},
|
},
|
||||||
es6: {
|
es6 : {
|
||||||
files: ['build/js/src/*.js'],
|
files: ['build/js/src/*.js'],
|
||||||
tasks: ['concat', 'babel', 'uglify', 'notify:watch']
|
tasks: ['concat', 'babel', 'uglify', 'notify:watch']
|
||||||
},
|
},
|
||||||
js: {
|
js : {
|
||||||
files: ['dist/js/adminlte.js', 'dist/js/app.js'],
|
files: ['dist/js/adminlte.js', 'dist/js/app.js'],
|
||||||
tasks: ['uglify', 'notify:watch']
|
tasks: ['uglify', 'notify:watch']
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue