1.1.0-beta.3 • Published 9 months ago
@ecar/babel-plugin-auto-i18n v1.1.0-beta.3
@ecar/babel-plugin-auto-i18n
function
auto transform chinese string to t invoke expression
usage
in babel config file like .babelrc,
{
"plugins": [["@ecar/babel-plugin-auto-i18n"]]
}TODO
1.0
- 支持jsxText内的文本转换
- 支持stringLiteral内的文本转换
- 支持templateElement内的文本转换
- 支持templateLiteral的文本,单复数/文本插槽功能
- Avoid unnecessary calls to the
useTranslationfunction. - unnecessary import will be tree-shaking by webpack
optimization: { sideEffects: false, }
- bench the performance of this plugin
2.0
- support option source language
1.1.0-beta.3
9 months ago