rsuite icon indicating copy to clipboard operation
rsuite copied to clipboard

Next.js - Class name prefix module parse failed: Unexpected token

Open elbasan opened this issue 4 years ago • 1 comments

Versions

package version
next ^9.5.1
react ^16.13.1
rsuite ^4.8.0

What is the expected behavior?

Modify the component's className prefix

What is the current behavior?

className prefix is not being modified

What are the steps to reproduce?

next.config.js:

const withImages = require('next-images');
const withLess = require('@zeit/next-less');
const webpack = require('webpack');

module.exports = withImages(
  withLess({
    lessLoaderOptions: {
      javascriptEnabled: true,
    },
    plugins: [
      //...
      new webpack.DefinePlugin({
        __RSUITE_CLASSNAME_PREFIX__: 'test-'
      })
    ]
  }),
);

custom-theme.less:

@import '~rsuite/lib/styles/themes/default/index.less';
@ns: test-;

elbasan avatar Aug 16 '20 21:08 elbasan

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Apr 16 '22 10:04 stale[bot]