3.0.3 • Published 1 month ago

html-segmentator v3.0.3

Weekly downloads
-
License
-
Repository
github
Last release
1 month ago

HTML Segmentator

A small library for splitting an HTML string into its top-level sections. Based on html5parser.

Install

npm install --save html-segmentator

Usage

import segmentator from 'html-segmentator';

// Splitting an HTML string into its top-level sections

const html = '<div><b>foo</b></div><i>bar</i>';
const segments = segmentator ( html );

console.log ( segments );
// [
//   { start: 0, end: 21 },
//   { start: 21, end: 31 }
// ]

License

  • Library MIT © Fabio Spampinato.
  • Tokenizer MIT © html5parser.
3.0.3

1 month ago

3.0.2

1 year ago

3.0.1

2 years ago

3.0.0

2 years ago

2.0.1

2 years ago

2.0.0

2 years ago

1.1.0

3 years ago

1.0.0

3 years ago