Replace jade to pug (#30)
* Replace jade to pug resolves #3 * Update geoip-lite
This commit is contained in:
parent
8cc163432e
commit
0a4a93cd74
12
Gruntfile.js
12
Gruntfile.js
@ -40,7 +40,7 @@ module.exports = function(grunt) {
|
||||
js: ['dist/js/*.*', '!dist/js/netstats.*'],
|
||||
css: ['dist/css/*.css', '!dist/css/netstats.*.css']
|
||||
},
|
||||
jade: {
|
||||
pug: {
|
||||
build: {
|
||||
options: {
|
||||
data: {
|
||||
@ -49,7 +49,7 @@ module.exports = function(grunt) {
|
||||
}
|
||||
},
|
||||
files: {
|
||||
'dist/index.html': 'src/views/index.jade'
|
||||
'dist/index.html': 'src/views/index.pug'
|
||||
}
|
||||
},
|
||||
build_pow: {
|
||||
@ -60,7 +60,7 @@ module.exports = function(grunt) {
|
||||
}
|
||||
},
|
||||
files: {
|
||||
'dist/index.html': 'src/pow/views/index.jade'
|
||||
'dist/index.html': 'src/pow/views/index.pug'
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -186,11 +186,11 @@ module.exports = function(grunt) {
|
||||
grunt.loadNpmTasks('grunt-contrib-clean');
|
||||
grunt.loadNpmTasks('grunt-contrib-copy');
|
||||
grunt.loadNpmTasks('grunt-contrib-concat');
|
||||
grunt.loadNpmTasks('grunt-contrib-jade');
|
||||
grunt.loadNpmTasks('grunt-contrib-pug');
|
||||
grunt.loadNpmTasks('grunt-contrib-cssmin');
|
||||
grunt.loadNpmTasks('grunt-contrib-uglify');
|
||||
|
||||
grunt.registerTask('default', ['clean:build', 'clean:js', 'clean:css', 'jade:build', 'copy:build', 'cssmin:build', 'concat:vendor', 'concat:scripts', 'uglify:app', 'concat:netstats', 'concat:css', 'clean:js', 'clean:css']);
|
||||
grunt.registerTask('pow', ['clean:build', 'clean:js', 'clean:css', 'jade:build_pow', 'copy:build_pow', 'cssmin:build', 'concat:vendor', 'concat:scripts', 'uglify:app', 'concat:netstats', 'concat:css', 'clean:js', 'clean:css']);
|
||||
grunt.registerTask('default', ['clean:build', 'clean:js', 'clean:css', 'pug:build', 'copy:build', 'cssmin:build', 'concat:vendor', 'concat:scripts', 'uglify:app', 'concat:netstats', 'concat:css', 'clean:js', 'clean:css']);
|
||||
grunt.registerTask('pow', ['clean:build', 'clean:js', 'clean:css', 'pug:build_pow', 'copy:build_pow', 'cssmin:build', 'concat:vendor', 'concat:scripts', 'uglify:app', 'concat:netstats', 'concat:css', 'clean:js', 'clean:css']);
|
||||
grunt.registerTask('poa', 'default');
|
||||
};
|
||||
|
@ -5,7 +5,7 @@ var bodyParser = require('body-parser');
|
||||
|
||||
// view engine setup
|
||||
app.set('views', path.join(__dirname, (process.env.LITE === 'true' ? '../src-lite/views' : '../src/views')));
|
||||
app.set('view engine', 'jade');
|
||||
app.set('view engine', 'pug');
|
||||
app.use(bodyParser.json());
|
||||
app.use(bodyParser.urlencoded({ extended: false }));
|
||||
app.use(express.static(path.join(__dirname, (process.env.LITE === 'true' ? '../dist-lite' : '../dist'))));
|
||||
@ -39,4 +39,4 @@ app.use(function(err, req, res, next) {
|
||||
});
|
||||
});
|
||||
|
||||
module.exports = app;
|
||||
module.exports = app;
|
||||
|
@ -17,16 +17,16 @@
|
||||
"d3": "3.5.17",
|
||||
"debug": "^4.1.0",
|
||||
"express": "^4.16.4",
|
||||
"geoip-lite": "^1.3.5",
|
||||
"geoip-lite": "^1.4.3",
|
||||
"grunt": "^1.0.3",
|
||||
"grunt-cli": "^1.3.2",
|
||||
"grunt-contrib-clean": "^2.0.0",
|
||||
"grunt-contrib-concat": "^1.0.1",
|
||||
"grunt-contrib-copy": "^1.0.0",
|
||||
"grunt-contrib-cssmin": "^3.0.0",
|
||||
"grunt-contrib-jade": "^1.0.0",
|
||||
"grunt-contrib-pug": "^3.0.0",
|
||||
"grunt-contrib-uglify": "^4.0.0",
|
||||
"jade": "^1.11.0",
|
||||
"pug": "^3.0.2",
|
||||
"lodash": "4.17.19",
|
||||
"primus": "^7.3.1",
|
||||
"primus-emit": "^1.0.0",
|
||||
|
@ -1,5 +1,5 @@
|
||||
//- index.jade
|
||||
extends ./layout.jade
|
||||
//- index.pug
|
||||
extends ./layout.pug
|
||||
|
||||
block content
|
||||
div.container-fluid(ng-controller='StatsCtrl')
|
@ -1,4 +1,4 @@
|
||||
//- layout.jade
|
||||
//- layout.pug
|
||||
doctype html
|
||||
html(ng-app="netStatsApp")
|
||||
head
|
Loading…
Reference in New Issue
Block a user