nuxt-resources-loader
Install
npm i nuxt-resources-loader# or yarn add nuxt-resources-loader
Usage
// nuxt.config.js moduleexports = modules: // Provide path to the file with resources 'nuxt-resources-loader' // or array of paths 'nuxt-resources-loader' // or the native options 'nuxt-resources-loader' resources:
Glob pattern matching
You can specify glob patterns to match your all of your files in the same directory.
// Specify a single pathresources: './path/to/resources/**/*.scss' // will match all files in folder and subdirectories// or an array of pathsresources: './path/to/resources/**/*.scss' './path/to/another/**/*.scss'
Note that sass-resources-loader will resolve your files in order. If you want your variables to be accessed across all of your mixins you should specify them in first place.
resources: './path/to/variables/vars.scss' './path/to/mixins/**/*.scss'
For more details see the official documentation