From 080366d6d4c5ece67a31deae77024b97fcfeadb8 Mon Sep 17 00:00:00 2001 From: Shift Date: Sat, 7 Jan 2023 20:33:22 +0000 Subject: [PATCH] Upgrade to Laravel Mix 6 --- package.json | 21 ++++++++++++++++----- webpack.mix.js | 17 +++++++++++++++++ 2 files changed, 33 insertions(+), 5 deletions(-) create mode 100644 webpack.mix.js diff --git a/package.json b/package.json index 5595f071f..00c650670 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,18 @@ { - "private": true, - "devDependencies": { - "gulp": "^3.8.8", - "laravel-elixir": "*" - } + "private": true, + "scripts": { + "dev": "npm run development", + "development": "mix", + "watch": "mix watch", + "watch-poll": "mix watch -- --watch-options-poll=1000", + "hot": "mix watch --hot", + "prod": "npm run production", + "production": "mix --production" + }, + "devDependencies": { + "axios": "^0.21", + "laravel-mix": "^6.0.6", + "lodash": "^4.17.19", + "postcss": "^8.1.14" + } } diff --git a/webpack.mix.js b/webpack.mix.js new file mode 100644 index 000000000..2a22dc120 --- /dev/null +++ b/webpack.mix.js @@ -0,0 +1,17 @@ +const mix = require('laravel-mix'); + +/* + |-------------------------------------------------------------------------- + | Mix Asset Management + |-------------------------------------------------------------------------- + | + | Mix provides a clean, fluent API for defining some Webpack build steps + | for your Laravel applications. By default, we are compiling the CSS + | file for the application as well as bundling up all the JS files. + | + */ + +mix.js('resources/js/app.js', 'public/js') + .postCss('resources/css/app.css', 'public/css', [ + // + ]);