From cab7a278030af214f0503fa705d2015661a9ac4d Mon Sep 17 00:00:00 2001 From: crupest Date: Thu, 11 Jun 2020 23:28:25 +0800 Subject: build(front): Not use service worker in development mode. --- Timeline/ClientApp/webpack.config.dev.js | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) (limited to 'Timeline/ClientApp/webpack.config.dev.js') diff --git a/Timeline/ClientApp/webpack.config.dev.js b/Timeline/ClientApp/webpack.config.dev.js index 7a38f2b6..c2f29700 100644 --- a/Timeline/ClientApp/webpack.config.dev.js +++ b/Timeline/ClientApp/webpack.config.dev.js @@ -2,9 +2,7 @@ const path = require('path'); const webpack = require('webpack'); const HtmlWebpackPlugin = require('html-webpack-plugin'); const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin'); -const CopyPlugin = require('copy-webpack-plugin'); const PnpWebpackPlugin = require('pnp-webpack-plugin'); -const WorkboxPlugin = require('workbox-webpack-plugin'); const { commonRules, htmlCommonConfig } = require('./webpack.common'); @@ -55,7 +53,7 @@ const config = { publicPath: '/', }, devServer: { - contentBase: false, + contentBase: path.resolve(__dirname, 'public/'), host: '0.0.0.0', port: 3000, publicPath: 'http://localhost:3000/', @@ -67,14 +65,6 @@ const config = { ...htmlCommonConfig, devServer: 'http://localhost:3000', }), - new CopyPlugin({ - patterns: [ - { - from: path.resolve(__dirname, 'public/'), - to: path.resolve(__dirname, 'dist/'), - }, - ], - }), new ForkTsCheckerWebpackPlugin({ tsconfig: './src/app/tsconfig.json', }), @@ -82,10 +72,6 @@ const config = { tsconfig: './src/sw/tsconfig.json', }), new webpack.HotModuleReplacementPlugin(), - new WorkboxPlugin.InjectManifest({ - swSrc: './src/sw/sw.ts', - maximumFileSizeToCacheInBytes: 15000000, - }), ], }; -- cgit v1.2.3