timdream / jszhuyin

JS 注音:JavaScript 自動選字注音輸入法;"Smart" Chinese Zhuyin Input Method in JavaScript.
https://jszhuyin.timdream.org/
MIT License
223 stars 19 forks source link

Optimize `JSZhuyin._insertPartialMatchingCandidates` #25

Open timdream opened 8 years ago

timdream commented 8 years ago

The remove-duplication operation in this function has been identified by Chrome DevTools Profiler as expensive. Should avoid pulling stuff out and then remove it.