1
0
Fork 0
mirror of https://gitlab.com/Oreolek/salet.git synced 2024-05-19 17:38:35 +03:00

pnpm / webpack / Laravel Mix updates

This commit is contained in:
Alexander Yakovlev 2021-07-15 20:55:55 +07:00
parent d2154b2c29
commit b493d0ea53
Signed by: oreolek
GPG key ID: 8D24103F5EE2A6C0
3 changed files with 1509 additions and 2927 deletions

View file

@ -7,7 +7,7 @@
"build": "NODE_ENV=production npm run mix", "build": "NODE_ENV=production npm run mix",
"start": "NODE_ENV=development npm run mix -- --watch", "start": "NODE_ENV=development npm run mix -- --watch",
"hot": "NODE_ENV=development npm run mix:hot", "hot": "NODE_ENV=development npm run mix:hot",
"mix": "webpack --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js", "mix": "webpack --progress --config=node_modules/laravel-mix/setup/webpack.config.js",
"mix:hot": "webpack-dev-server --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js" "mix:hot": "webpack-dev-server --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js"
}, },
"private": true, "private": true,
@ -19,17 +19,17 @@
"@babel/preset-env": "^7.14.7", "@babel/preset-env": "^7.14.7",
"babel-loader": "^8.2.2", "babel-loader": "^8.2.2",
"browser-sync": "^2.27.4", "browser-sync": "^2.27.4",
"browser-sync-webpack-plugin": "2.2.2", "browser-sync-webpack-plugin": "2.3.0",
"coffee-loader": "^0.9.0", "coffee-loader": "^3.0.0",
"coffeescript": "^2.5.1", "coffeescript": "^2.5.1",
"css-loader": "^3.6.0", "css-loader": "^5.2.6",
"laravel-mix": "^4.1.4", "laravel-mix": "^6.0.25",
"postcss-loader": "^3.0.0", "postcss-loader": "^6.1.1",
"sass": "^1.35.2", "sass": "^1.35.2",
"sass-loader": "~7.3.1", "sass-loader": "^12.1.0",
"style-loader": "^1.3.0", "style-loader": "^3.1.0",
"vue-template-compiler": "^2.6.14", "vue-template-compiler": "^2.6.14",
"webpack": "^4.46.0", "webpack": "^5.44.0",
"webpack-cli": "^3.3.12" "webpack-cli": "^4.7.2"
} }
} }

File diff suppressed because it is too large Load diff

View file

@ -1,7 +1,7 @@
const mix = require('laravel-mix'); const mix = require('laravel-mix');
// Public path helper // Public path helper
const publicPath = (path) => `${mix.config.publicPath}/${path}`; const publicPath = (path) => `dist/${path}`;
// Source path helper // Source path helper
const src = (path) => `./${path}`; const src = (path) => `./${path}`;
@ -9,10 +9,7 @@ const src = (path) => `./${path}`;
// Public Path // Public Path
mix mix
.setPublicPath('./dist') .setPublicPath('./dist')
.setResourceRoot('/') .setResourceRoot('/');
.webpackConfig({
output: { publicPath: mix.config.resourceRoot },
});
// Browsersync // Browsersync
mix.browserSync('example.test'); mix.browserSync('example.test');