Vue CLI 3 sass-resources-loader - Options.loaders undefined : <p>I was able to successfully configure a new Vue project using the 3.0 version of the CLI to use <code>sass-resource-loader</code> a few weeks ago using the information posted here: <a href="https://stackoverflow.com/questions/49086021/using-sass-resources-loader-with-vue-cli-v3-x/50492650#50492650">Using sass-resources-loader with vue-cli v3.x</a></p>

<p>However, after updating everything today I'm encountering the following error when running <code>npm run serve</code>:</p>

<p><code>TypeError: Cannot read property 'scss' of undefined</code></p>

<p>the only options that seem to be getting passed into <code>.tap(options)</code> are: </p>

<p><code>{ compilerOptions: { preserveWhitespace: false } }</code></p>

<p>I don't currently know enough about <code>chainWebpack</code> to effectively debug, but I'm working on it. If anyone has any insights into what's changed to cause this error, it'd be greatly appreciated.</p>

<p>my <code>vue.config.js</code>:</p>

<pre><code>const path = require('path')

module.exports = {
  chainWebpack: (config) =&gt; {
    config
      .module
      .rule('vue')
      .use('vue-loader')
      .tap((options) =&gt; {
        console.log(options)
        options.loaders.scss = options.loaders.scss.concat({
          loader: 'sass-resources-loader',
          options: {
            resources: [
              path.resolve('./src/scss/_variables.scss'),
              path.resolve('./src/scss/_mixins.scss')
            ]
          },
        })
        return options
      })
    config
      .module
      .rule('scss')
      .use('sass-resources-loader')
      .loader('sass-resources-loader')
      .options({
        resources: [
          path.resolve('./src/scss/_variables.scss'),
          path.resolve('./src/scss/_mixins.scss')
        ]
      })
  }
}
</code></pre>
