Package Exports
- pinyin-split
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (pinyin-split) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Pinyin Split
Install
npm install pinyin-splitUsage
const split = require('pinyin-split')
split('wodemaoxihuanheniunai')
.then(console.log) // ['wo', 'de', 'mao', 'xi', 'huan', 'he', 'niu', 'nai']
.catch(console.error)
split('wo de mao xihuan he niunai')
.then(console.log) // ['wo', 'de', 'mao', 'xi', 'huan', 'he', 'niu', 'nai']
.catch(console.error)
split('ni jiao shenme mingzi', {keepSpaces: true})
.then(console.log) // ['ni', ' ', 'jiao', ' ', 'shen', 'me', ' ', 'ming', 'zi']
.catch(console.error)Related
pinyin-utilsfind-hanzihsk-wordspinyin-or-hanzihanzi-to-pinyinpinyin-convertpinyin-restpinyin-apipinyin-bot-corepinyin-telegrampinyin-messenger
Contributing
If you have a question, found a bug or want to propose a feature, have a look at the issues page.