/regionize

A tiny library to flow HTML through multiple regions

Primary LanguageTypeScriptMIT LicenseMIT

Regionize

⚠️ Note that the main branch is tracking a 1.0.0 refactor which is in alpha and is still being stabilized. Documentation has not been updated and refers to the 0.1.X version

npm Build Status codecov Bundle Size

A bare-bones, asynchronous javascript library to flow HTML content across a series of separate elements. It makes no attempt to handle the styling of elements that break across regions.

Note that Regionize is inspired by the proposed CSS Regions spec, but does not attempt to polyfill that API. Instead, it provides utilities to determine how much of an DOM tree can fit inside a statically-sized container, and how much overflows, in plain javascript.

Regionize powers bindery.js.

Usage

npm i -s regionize

TODO: docs