mardi 3 décembre 2019

Laravel with ReactJS - Sass not being loaded

I have built my components and imported them into the laravel framework. I have set react as preset and the App loads. the Sass files are in each folder that has a component eg.

\ComponentX
--ComponentX.js
--ComponentX.module.scss

The files load fine but there is no css being added.

I have done 'npm install sass-node' - that is all so far.

I tried to place sass file in the 'sass' folder that is given to us when laravel is installed but nothing happens. is there further configuration required?

WEBPACKMIX

const mix = require('laravel-mix');

mix.react('resources/js/app.js', 'public/js')
   .sass('resources/sass/app.scss', 'public/css');

mix.browserSync('localhost:8000');

Thank you in advance



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire