title: Storybook + antd less loader
body: <p>I've been using <a href="https://www.npmjs.com/package/storybook-addon-customize-antd-theme" rel="nofollow noreferrer">storybook-addon-customize-antd-theme</a> for a while, but it seems unmaintained and I realize I am never using it to customize the theme anyway, just load the less files. I've also been recently running into build issues that are solved by removing the add on.</p>
  <p>I've been trying to replace it by just using the appropriate webpack loader config like this:</p>
  <pre><code>addons: [
      ...,
      {
        &quot;name&quot;: &quot;@storybook/preset-create-react-app&quot;,
        &quot;options&quot;: {
          &quot;craOverrides&quot;: {
            &quot;fileLoaderExcludes&quot;: [&quot;less&quot;]
          }
        }
      }
  ],
  webpackFinal: async (config) =&gt; {
      config.module.rules.push({
        // this is for both less and scss
        test: /.*\.(?:le|c)ss$/,
        use: [
          'style-loader',
          {
            loader: 'css-loader',
            options: {
              modules: false
            }
          },
          {
            loader: 'less-loader',
            options: {
              lessOptions: {
                javascriptEnabled: true
              }
            }
          }
        ]
      });
      return config 
  }
  </code></pre>
  <p>But I am receiving this error:</p>
  <pre><code>// https://github.com/ant-design/ant-motion/issues/44
  .bezierEasingMixin();
  ^
  Inline JavaScript is not enabled. Is it set in your options?
  </code></pre>
  <p>Which makes it seem like the rule isn't being obeyed, because I have <code>javascriptEnabled: true</code> in the less loader.</p>
  <p>What gives?</p>