mozillazg / go-pinyin

汉字转拼音
https://godoc.org/github.com/mozillazg/go-pinyin
MIT License
1.6k stars 194 forks source link

字典不匹配希望保留 #55

Closed ghost closed 3 years ago

ghost commented 3 years ago

希望对于字典没有匹配的字符,不要返回空切片,而是原样返回,这样对于一些汉字和其他字符混合的情况可以输出较全的信息

mozillazg commented 3 years ago

@APandaThief 可以看看这个参数是否满足你的需求: https://pkg.go.dev/github.com/mozillazg/go-pinyin#example-Pinyin-FallbackCustom1

ghost commented 3 years ago

@mozillazg 是的就是这个,不好意思,没看见