Webpack conf now outputs to public/dist.
This commit is contained in:
		| @@ -16,9 +16,10 @@ const environment = isProd | |||||||
|  |  | ||||||
| const webpackConfig = merge(commonConfig(false), { | const webpackConfig = merge(commonConfig(false), { | ||||||
|   mode: "production", |   mode: "production", | ||||||
|  |   stats: { children: false }, | ||||||
|   output: { |   output: { | ||||||
|     path: helpers.root("dist"), |     path: helpers.root("public/dist"), | ||||||
|     publicPath: "/dist/", |     publicPath: "/public/dist/", | ||||||
|     filename: "js/[name].bundle.[hash:7].js" |     filename: "js/[name].bundle.[hash:7].js" | ||||||
|   }, |   }, | ||||||
|   optimization: { |   optimization: { | ||||||
|   | |||||||
| @@ -65,8 +65,8 @@ passport.serializeUser(User.serializeUser()); | |||||||
| passport.deserializeUser(User.deserializeUser()); | passport.deserializeUser(User.deserializeUser()); | ||||||
|  |  | ||||||
| // files | // files | ||||||
| app.use("/assets", express.static(path.join(__dirname, "assets"))); | app.use("/public", express.static(path.join(__dirname, "public"))); | ||||||
| app.use("/dist", express.static(path.join(__dirname, "dist"))); | app.use("/service-worker.js", express.static(path.join(__dirname, "public/sw/serviceWorker.js"))); | ||||||
|  |  | ||||||
| // api endpoints | // api endpoints | ||||||
| app.use("/api/", apiRouter); | app.use("/api/", apiRouter); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user