2 Star 0 Fork 0

mirrors_svgdotjs/svg.screenbbox.js

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
Gruntfile.js 1.63 KB
一键复制 编辑 原始数据 按行查看 历史
Ulrich-Matthias Schäfer 提交于 2015-11-07 02:50 . Initial commit v0.1.0
'use strict';
module.exports = function(grunt) {
// Project configuration.
grunt.initConfig({
// Metadata.
pkg: grunt.file.readJSON('package.json'),
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.name %>;' +
' Licensed <%= pkg.license %> */\n',
// Task configuration.
clean: {
files: ['dist']
},
concat: {
options: {
banner: '<%= banner %>\n;(function () {\n',
stripBanners: true,
separator:'\n\n',
footer:'\n}).call(this);'
},
dist: {
src: ['src/<%= fileName %>.js'],
dest: 'dist/<%= fileName %>.js'
},
},
uglify: {
options: {
banner: '<%= banner %>'
},
dist: {
src: '<%= concat.dist.dest %>',
dest: 'dist/<%= fileName %>.min.js'
},
},
watch: {
scripts: {
files: ['src/*.js'],
tasks: ['default']
},
},
bumper: {
options: {
files: ['package.json', 'bower.json'],
tagName: "%VERSION%"
}
},
});
// These plugins provide necessary tasks.
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-bumper');
grunt.config('fileName', grunt.config('pkg').name.slice(0, -3));
// Default task.
grunt.registerTask('default', ['clean', 'concat', 'uglify']);
};
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/mirrors_svgdotjs/svg.screenbbox.js.git
git@gitee.com:mirrors_svgdotjs/svg.screenbbox.js.git
mirrors_svgdotjs
svg.screenbbox.js
svg.screenbbox.js
master

搜索帮助