frontend: use webpack instead of vulcanize

This commit is contained in:
Marcin Lulek 2018-10-30 15:24:35 +01:00
parent 33f90bf320
commit 69b8d6a77f
16 changed files with 2946 additions and 310 deletions

View file

@ -1,4 +1,12 @@
var gruntConfig = require('./grunt_config.json');
var webpackConfig = require('./webpack.config');
gruntConfig["webpack"] = {
options: {
stats: !process.env.NODE_ENV || process.env.NODE_ENV === 'development'
},
prod: webpackConfig,
dev: Object.assign({ watch: false }, webpackConfig)
};
module.exports = function(grunt) {
grunt.initConfig(gruntConfig);
@ -7,8 +15,7 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-vulcanize');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.registerTask('default', ['less:production', 'less:components', 'concat:polymercss', 'copy', 'concat:dist', 'vulcanize']);
grunt.loadNpmTasks('grunt-webpack');
grunt.registerTask('default', ['less:production', 'less:components', 'concat:polymercss', 'copy', 'webpack', 'concat:dist']);
};