{"library":"graphemer","type":"library","category":null,"description":"Graphemer is a JavaScript and TypeScript library designed to accurately split strings into user-perceived characters, also known as 'extended grapheme clusters' in Unicode terminology. It addresses the complexities of Unicode, where a single visual character can be composed of multiple JavaScript characters (e.g., emojis, combining marks), which standard string operations often fail to handle correctly. The library is currently stable at version 1.4.0, which supports Unicode 15 and below. It follows a release cadence tied to new Unicode versions, typically updating annually. Key differentiators include its adherence to UAX #29's Default Grapheme Cluster Boundary rules, providing a robust solution for internationalization (i18n) and accurate character counting that standard JavaScript methods like `String.prototype.length` or simple `String.prototype.split('')` cannot achieve, especially with complex scripts and emoji sequences.","language":"javascript","status":"active","version":"1.4.0","tags":["javascript","utf-8","strings","emoji","split","typescript"],"last_verified":"Wed May 27","install":[{"cmd":"npm install graphemer","imports":["import Graphemer from 'graphemer';","const Graphemer = require('graphemer').default;"]},{"cmd":"yarn add graphemer","imports":[]},{"cmd":"pnpm add graphemer","imports":[]}],"homepage":null,"github":"https://github.com/flmnt/graphemer","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/graphemer","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/graphemer/compatibility"}}