Browse Source

📝 Add FAQ for ConfigProvider locale not working

pull/19643/head
afc163 5 years ago
parent
commit
c9682fcd6e
No known key found for this signature in database GPG Key ID: 5F00908D72002306
  1. 6
      components/config-provider/index.en-US.md
  2. 6
      components/config-provider/index.zh-CN.md

6
components/config-provider/index.en-US.md

@ -44,3 +44,9 @@ Some component use dynamic style to support wave effect. You can config `csp` pr
| locale | language package setting, you can find the packages in [antd/es/locale](http://unpkg.com/antd/es/locale/) | object | 3.21.0 |
| prefixCls | set prefix class | string | ant | 3.12.0 |
| pageHeader | Unify the ghost of pageHeader ,Ref [pageHeader](<(/components/page-header)> | { ghost:boolean } | 'true' | 3.24.0 |
## FAQ
#### Locale problem is still existed in DatePicker even ConfigProvider `locale` is used?
Please make sure you set moment locale by `moment.locale('zh-cn')`, or you don't have two moment of different version.

6
components/config-provider/index.zh-CN.md

@ -45,3 +45,9 @@ return (
| locale | 语言包配置,语言包可到 [antd/es/locale](http://unpkg.com/antd/es/locale/) 目录下寻找 | object | - | 3.21.0 |
| prefixCls | 设置统一样式前缀 | string | ant | 3.12.0 |
| pageHeader | 统一设置 pageHeader 的 ghost,参考 [pageHeader](<(/components/page-header)>) | { ghost: boolean } | 'true' | 3.24.0 |
## FAQ
#### 为什么我使用了 ConfigProvider `locale`,时间类组件的国际化还有问题?
请检查是否设置了 `moment.locale('zh-cn')`,或者是否有两个版本的 moment 共存。

Loading…
Cancel
Save