tiny-wcwidth
v1.0.0
Published
Determine columns needed for a wide character
Downloads
3
Readme
tiny-wcwidth
Determine columns needed for a wide character.
npm i tiny-wcwidth
Usage
const wcwidth = require('tiny-wcwidth')
'한'.length // 1
wcwidth('한') // 2
'한글'.length // 2
wcwidth('한글') // 4
'🤦🏼♂️'.length // 7
wcwidth('🤦🏼♂️') // 2
Simplified fork of wcwidth.js with added support for multi-codepoint emojis.
License
MIT