source: imaps-frontend/node_modules/text-segmentation/README.md@ 79a0317

main
Last change on this file since 79a0317 was 79a0317, checked in by stefan toskovski <stefantoska84@โ€ฆ>, 4 days ago

F4 Finalna Verzija

  • Property mode set to 100644
File size: 982 bytes
Lineย 
1text-segmentation
2==============
3
4![CI](https://github.com/niklasvh/text-segmentation/workflows/CI/badge.svg?branch=main)
5[![NPM Downloads](https://img.shields.io/npm/dm/text-segmentation.svg)](https://www.npmjs.org/package/text-segmentation)
6[![NPM Version](https://img.shields.io/npm/v/text-segmentation.svg)](https://www.npmjs.org/package/text-segmentation)
7
8A JavaScript library for Grapheme Breaking and identifying Grapheme Boundaries, [implementing the Unicode Line Breaking Algorithm (UAX #29)](https://unicode.org/reports/tr29/)
9
10### Installing
11You can install the module via npm:
12
13 npm install text-segmentation
14
15### Example
16```javascript
17import {splitGraphemes} from 'text-segmentation';
18
19const graphemes = splitGraphemes('Hello ๐Ÿ‘จโ€๐Ÿ‘ฉโ€๐Ÿ‘งโ€๐Ÿ‘ฆ!');
20```
21
22### Testing
23You can run the test suite with:
24
25 npm test
26
27The library implements all the [GraphemeBreakTest.txt tests](https://www.unicode.org/Public/13.0.0/ucd/auxiliary/GraphemeBreakTest.txt).
Note: See TracBrowser for help on using the repository browser.