转载自:https://blog.csdn.net/weixin_43013802/article/details/132870349
全局汉化,在main.ts中引入下面代码:
import{ ConfigProvider }from'antd' import locale from 'antd/locale/zh_CN'; import 'dayjs/locale/zh-cn';ReactDOM.createRoot(document.getElementById('root')!).render(<ConfigProvider locale={locale}><App /></ConfigProvider> )
汉化后: