Skip to content

Commit

Permalink
feat(doc): update migration guide
Browse files Browse the repository at this point in the history
- ConfigProvider prefixCls to "zarm-v3"
- sass-loader options difference version guide
  • Loading branch information
aiyogg committed Aug 2, 2024
1 parent 2f43570 commit a07c67d
Showing 1 changed file with 24 additions and 4 deletions.
28 changes: 24 additions & 4 deletions packages/site/web/docs/migration-v3.md
Original file line number Diff line number Diff line change
Expand Up @@ -300,17 +300,37 @@ module.exports = {
{
loader: 'sass-loader'
+ options: {
+ sassOptions: {
+ additionalData: '$prefixCls: "za-v3";'
+ }
+ additionalData: '$prefixCls: "zarm-v3";'
+ }
}
],
},
};
```

3. 配置 ConfigProvider prefixCls
- 如果你项目中使用的 `sass-loader` 版本 < 9.00 且 >= 8.0.0,则将 `additionalData` 改为 `prependData`

```diff
{
loader: 'sass-loader',
+ options: {
+ prependData: '$prefixCls: "zarm-v3";'
+ }
}
```

- 如果你项目中使用的 `sass-loader` 版本 < 8.0.0,则将 `additionalData` 改为 `data`

```diff
{
loader: 'sass-loader',
+ options: {
+ data: '$prefixCls: "zarm-v3";'
+ }
}
```

1. 配置 ConfigProvider prefixCls

```tsx
import * as React from 'react';
Expand Down

0 comments on commit a07c67d

Please sign in to comment.