@textlint-rule/tokenize-english

2.0.2 • Public • Published

@textlint-rule/tokenize-english

Javascript tokenizer for english sentences.

Installation

$ npm install @textlint-rule/tokenize-english

Usage

var tokenize = require('@textlint-rule/tokenize-text')();
var tokenizeEnglish = require('@textlint-rule/tokenize-english')(tokenize);

var tokens = tokenizeEnglish.sentences("On Jan. 20, former Sen. Barack Obama became the 44th President of the U.S. Millions attended the Inauguration.")

/*
[ { index: 0,
    value: 'On Jan. 20, former Sen. Barack Obama became the 44th President of the U.S.',
    offset: 74 },
  { index: 74,
    value: ' Millions attended the Inauguration.',
    offset: 36 } ]
*/

Readme

Keywords

none

Package Sidebar

Install

npm i @textlint-rule/tokenize-english

Weekly Downloads

106

Version

2.0.2

License

Apache-2.0

Unpacked Size

28.3 kB

Total Files

9

Last publish

Collaborators

  • azu
  • nodaguti
  • 0x6b
  • hata6502
  • textlint-user