aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/webpack.config.js
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2019-01-08 21:30:38 +0800
committerFabio Berger <me@fabioberger.com>2019-01-08 21:30:38 +0800
commit1631031fa74894143cb6835030b7dcd44d7c3c6b (patch)
tree06dea01cc64fb42905a5f95c95f4b3e16ecfe744 /packages/website/webpack.config.js
parent0bcb81d3a918fbcf71d68f42fa661d884d5d74cf (diff)
parent0ac36cef288deecd36caa601c53d13517eef5ca8 (diff)
downloaddexon-sol-tools-1631031fa74894143cb6835030b7dcd44d7c3c6b.tar
dexon-sol-tools-1631031fa74894143cb6835030b7dcd44d7c3c6b.tar.gz
dexon-sol-tools-1631031fa74894143cb6835030b7dcd44d7c3c6b.tar.bz2
dexon-sol-tools-1631031fa74894143cb6835030b7dcd44d7c3c6b.tar.lz
dexon-sol-tools-1631031fa74894143cb6835030b7dcd44d7c3c6b.tar.xz
dexon-sol-tools-1631031fa74894143cb6835030b7dcd44d7c3c6b.tar.zst
dexon-sol-tools-1631031fa74894143cb6835030b7dcd44d7c3c6b.zip
Merge branch 'development' into feature/order-watcher/dockerize
* development: (898 commits) Fixed merge conflict from development Ran prettier Doc generation working for changes by dutch auction wrapper added changelog entry for monorepo-scripts Hide dutch auction wrapper from docs -- hopefully this will prevent the "must export Web3Wrapper" error from doc generation relaxed version on contract-extension dependencies Added NetworkID 50 address for dutch auction wrapper removed manual updte of package.json version export dutch auction wrapper types from 0x.js Export dutch auction wrapper in 0x.js ran prettier Minor documentation updates to dutch auction wrapper `afterAuctionDetails` -> `auctionDetails` Added @todo for including dutch auction addresses once deployed Ran prettier & linter Removed redundant assignment removed needless newline on contract-wrappers changelog removed timestamp from changelog for abi-gen-wrappers added dutch auction address for testnets removed .only ...
Diffstat (limited to 'packages/website/webpack.config.js')
-rw-r--r--packages/website/webpack.config.js29
1 files changed, 28 insertions, 1 deletions
diff --git a/packages/website/webpack.config.js b/packages/website/webpack.config.js
index 33d5f648b..d9bdd91ad 100644
--- a/packages/website/webpack.config.js
+++ b/packages/website/webpack.config.js
@@ -3,6 +3,7 @@ const webpack = require('webpack');
const TerserPlugin = require('terser-webpack-plugin');
const RollbarSourceMapPlugin = require('rollbar-sourcemap-webpack-plugin');
const childProcess = require('child_process');
+const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
const GIT_SHA = childProcess
.execSync('git rev-parse HEAD')
@@ -55,6 +56,21 @@ const config = {
test: /\.css$/,
loaders: ['style-loader', 'css-loader'],
},
+ {
+ test: /\.svg$/,
+ use: [
+ {
+ loader: "react-svg-loader",
+ options: {
+ svgo: {
+ plugins: [
+ { removeViewBox: false }
+ ],
+ }
+ }
+ }
+ ]
+ },
],
},
optimization: {
@@ -70,6 +86,7 @@ const config = {
],
},
devServer: {
+ host: '0.0.0.0',
port: 3572,
historyApiFallback: {
// Fixes issue where having dots in URL path that aren't part of fileNames causes webpack-dev-server
@@ -85,6 +102,13 @@ const config = {
],
},
disableHostCheck: true,
+ // Fixes assertion error
+ // Source: https://github.com/webpack/webpack-dev-server/issues/1491
+ https: {
+ spdy: {
+ protocols: ['http/1.1']
+ }
+ },
},
};
@@ -92,6 +116,9 @@ module.exports = (_env, argv) => {
let plugins = [];
if (argv.mode === 'development') {
config.mode = 'development';
+ plugins.concat([
+ new BundleAnalyzerPlugin(),
+ ]);
} else {
config.mode = 'production';
plugins = plugins.concat([
@@ -109,7 +136,7 @@ module.exports = (_env, argv) => {
new RollbarSourceMapPlugin({
accessToken: '32c39bfa4bb6440faedc1612a9c13d28',
version: GIT_SHA,
- publicPath: 'https://0xproject.com/',
+ publicPath: 'https://0x.org/',
}),
]);
}