2022-02-11 17:26:15 +01:00
|
|
|
const mix = require('laravel-mix');
|
|
|
|
|
2022-04-14 10:49:56 +02:00
|
|
|
mix.options({
|
|
|
|
fileLoaderDirs: {
|
|
|
|
fonts: 'diary/public/fonts'
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
2022-02-11 17:26:15 +01:00
|
|
|
mix
|
|
|
|
.webpackConfig({
|
|
|
|
resolve: {
|
|
|
|
fallback: {
|
|
|
|
crypto: require.resolve("crypto-browserify"),
|
|
|
|
stream: require.resolve("stream-browserify")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
})
|
|
|
|
.ts('resources/js/app.ts', 'public/js')
|
|
|
|
.react()
|
2022-04-14 10:49:56 +02:00
|
|
|
.sass('resources/sass/app.scss', 'public/css')
|
|
|
|
.copyDirectory('resources/img/**', 'public/img')
|
|
|
|
.copyDirectory('resources/fonts/**', 'public/fonts');
|
2022-02-11 17:26:15 +01:00
|
|
|
|
|
|
|
/*
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
| 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.postCss('resources/css/app.css', 'public/css', [
|
|
|
|
require('postcss-import'),
|
|
|
|
require('tailwindcss'),
|
|
|
|
require('autoprefixer'),
|
|
|
|
]);
|