mirror of
https://github.com/niklasvh/html2canvas.git
synced 2023-08-10 21:13:10 +03:00
Revert back to grunt-contrib-connect
This commit is contained in:
parent
3b8d4dece2
commit
c9993a7237
27
Gruntfile.js
27
Gruntfile.js
@ -43,18 +43,20 @@ module.exports = function(grunt) {
|
||||
}
|
||||
}
|
||||
},
|
||||
express: {
|
||||
connect: {
|
||||
server: {
|
||||
options: {
|
||||
port: 8080,
|
||||
bases: './'
|
||||
base: './',
|
||||
keepalive: true
|
||||
}
|
||||
},
|
||||
cors: {
|
||||
options: {
|
||||
port: 8081,
|
||||
bases: './',
|
||||
middleware: [
|
||||
base: './',
|
||||
middleware: function(connect, options) {
|
||||
return [
|
||||
function(req, res, next) {
|
||||
if (req.url !== '/tests/assets/image2.jpg') {
|
||||
next();
|
||||
@ -63,19 +65,24 @@ module.exports = function(grunt) {
|
||||
res.setHeader("Access-Control-Allow-Origin", "*");
|
||||
res.end(require("fs").readFileSync('tests/assets/image2.jpg'));
|
||||
}
|
||||
]
|
||||
];
|
||||
}
|
||||
}
|
||||
},
|
||||
proxy: {
|
||||
options: {
|
||||
port: 8082,
|
||||
middleware: [proxy()]
|
||||
middleware: function(connect, options) {
|
||||
return [
|
||||
proxy()
|
||||
];
|
||||
}
|
||||
}
|
||||
},
|
||||
ci: {
|
||||
options: {
|
||||
port: 8080,
|
||||
bases: './'
|
||||
base: './'
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -171,12 +178,12 @@ module.exports = function(grunt) {
|
||||
grunt.loadNpmTasks('grunt-contrib-uglify');
|
||||
grunt.loadNpmTasks('grunt-contrib-jshint');
|
||||
grunt.loadNpmTasks('grunt-contrib-qunit');
|
||||
grunt.loadNpmTasks('grunt-express');
|
||||
grunt.loadNpmTasks('grunt-contrib-connect');
|
||||
grunt.loadNpmTasks('grunt-execute');
|
||||
|
||||
grunt.registerTask('server', ['express:cors', 'express:proxy', 'express:server', 'express-keepalive']);
|
||||
grunt.registerTask('server', ['connect:cors', 'connect:proxy', 'connect:server']);
|
||||
grunt.registerTask('build', ['execute', 'concat', 'uglify']);
|
||||
grunt.registerTask('default', ['jshint', 'build', 'qunit']);
|
||||
grunt.registerTask('travis', ['jshint', 'build','qunit', 'express:ci', 'express:cors', 'webdriver']);
|
||||
grunt.registerTask('travis', ['jshint', 'build','qunit', 'connect:ci', 'connect:cors', 'webdriver']);
|
||||
|
||||
};
|
||||
|
12
package.json
12
package.json
@ -23,13 +23,13 @@
|
||||
"base64-arraybuffer": ">= 0.1.0",
|
||||
"bluebird": "^2.3.2",
|
||||
"grunt": "^0.4.5",
|
||||
"grunt-contrib-concat": "*",
|
||||
"grunt-contrib-jshint": "*",
|
||||
"grunt-contrib-qunit": "*",
|
||||
"grunt-contrib-uglify": "*",
|
||||
"grunt-contrib-watch": "~0.5.1",
|
||||
"grunt-contrib-concat": "^0.5.0",
|
||||
"grunt-contrib-connect": "^0.8.0",
|
||||
"grunt-contrib-jshint": "^0.10.0",
|
||||
"grunt-contrib-qunit": "^0.5.2",
|
||||
"grunt-contrib-uglify": "^0.6.0",
|
||||
"grunt-contrib-watch": "^0.6.1",
|
||||
"grunt-execute": "^0.2.2",
|
||||
"grunt-express": "^1.4.1",
|
||||
"html2canvas-proxy": "0.0.2",
|
||||
"humanize-duration": "^2.0.1",
|
||||
"lodash": "^2.4.1",
|
||||
|
Loading…
Reference in New Issue
Block a user