From feffab19a4814b6e44cdd08aeca515e69ddeecb4 Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Mon, 11 Jul 2016 11:58:32 +0300 Subject: backport npm/webpack stuff (WIP) --- juick-www/webpack.config.js | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 juick-www/webpack.config.js (limited to 'juick-www/webpack.config.js') diff --git a/juick-www/webpack.config.js b/juick-www/webpack.config.js new file mode 100644 index 00000000..d72c23e5 --- /dev/null +++ b/juick-www/webpack.config.js @@ -0,0 +1,25 @@ +var webpack = require("webpack") +var globby = require("globby") +var ExtractTextPlugin = require("extract-text-webpack-plugin") +module.exports = { + entry: { + "scripts" : globby.sync([ + __dirname + "/src/main/static/*.*" + ]) + }, + output: { + path: __dirname + "/src/main/webapp", + filename: "[name].js" + }, + module: { + loaders: [ + { test: /\.css$/, loader: ExtractTextPlugin.extract("style-loader", "css-loader") }, + { test: /scripts\.js$/, exclude: /node_modules/, loader: "expose?Juick" }, + ] + }, + plugins: [ + new ExtractTextPlugin("style.css", { + allChunks: true + }) + ] +} \ No newline at end of file -- cgit v1.2.3