Level 4
Did you figure this out? I'm trying to do the same thing.
I am trying to use VuetifyLoaderPlugin with Laravel mix and I keep getting the following error on edge browser:
"SCRIPT1028: Expected identifier, string or number"
My webpack.mix file looks like this
const mix = require('laravel-mix');
const VuetifyLoaderPlugin = require('vuetify-loader/lib/plugin')
mix.webpackConfig({
plugins: [new VuetifyLoaderPlugin()]
});
mix.js('resources/js/app.js', 'public/js');
mix.sass('resources/sass/app.scss', 'public/css');
I found the issue here https://github.com/vuetifyjs/vuetify/issues/8279
The solution seems to be
// vue.config.js
module.exports = {
...,
transpileDependencies: ['vuetify'],
};
But I don't know how to apply this to laravel mix. Any ideas?
I did fix it by adding "case-sensitive-paths-webpack-plugin"
here is a working example
const mix = require('laravel-mix');
const VuetifyLoaderPlugin = require('vuetify-loader/lib/plugin');
const CaseSensitivePathsPlugin = require('case-sensitive-paths-webpack-plugin');
var webpackConfig = {
module: {
rules: [{
test: /\.js?$/,
use: [{
loader: 'babel-loader',
options: mix.config.babel()
}]
}]
},
plugins: [
new VuetifyLoaderPlugin(),
new CaseSensitivePathsPlugin(),
]
}
mix.webpackConfig(webpackConfig);
Please or to participate in this conversation.