diff --git a/webpack.config.js b/webpack.config.babel.js similarity index 80% rename from webpack.config.js rename to webpack.config.babel.js index ed57558..adec19e 100644 --- a/webpack.config.js +++ b/webpack.config.babel.js @@ -1,12 +1,12 @@ -const path = require('path'); -const ExtractTextPlugin = require('extract-text-webpack-plugin'); -const HtmlWebpackPlugin = require('html-webpack-plugin'); -const webpack = require('webpack'); -const MinifyPlugin = require("babel-minify-webpack-plugin"); +import path from 'path'; +import ExtractTextPlugin from 'extract-text-webpack-plugin'; +import HtmlWebpackPlugin from 'html-webpack-plugin'; +import webpack from 'webpack'; +import MinifyPlugin from 'babel-minify-webpack-plugin'; const ENV = process.env.NODE_ENV || 'development'; -module.exports = { +export default { entry: ['babel-polyfill', './src/entry.js'], output: { path: path.resolve(__dirname, 'static', 'js'), @@ -17,12 +17,12 @@ module.exports = { rules: [ { - enforce: "pre", + enforce: 'pre', test: /\.js$/, exclude: [ /node_modules/, ], - loader: "eslint-loader", + loader: 'eslint-loader', options: { emitWarning: true } @@ -30,7 +30,7 @@ module.exports = { { test: /\.js/, include: [ - path.resolve(__dirname, "src"), + path.resolve(__dirname, 'src'), ], exclude: [ /node_modules/, @@ -55,7 +55,7 @@ module.exports = { test: /\.woff2?(\?v=[0-9]\.[0-9]\.[0-9])?$/, // Limiting the size of the woff fonts breaks font-awesome ONLY for the extract text plugin // loader: "url?limit=10000" - use: "url-loader" + use: 'url-loader' }, { test: /\.(ttf|eot|svg)(\?[\s\S]+)?$/, @@ -69,12 +69,12 @@ module.exports = { devServer: { contentBase: './', historyApiFallback: true, - host: "0.0.0.0", + host: '0.0.0.0', hot: true, port: 3000, proxy: { - "/api": "http://localhost:5000", - "/auth": "http://localhost:5000" + '/api': 'http://localhost:5000', + '/auth': 'http://localhost:5000' } },