@3kles/richtext-core
v1.4.1
Published
The native AST, validation, normalization, JSON v1, and UTF-16 positions. This package is independent of the DOM and Angular.
Keywords
Readme
@3kles/richtext-core
The native AST, validation, normalization, JSON v1, and UTF-16 positions. This package is independent of the DOM and Angular.
This experimental ESM package uses the native engine. src/public-api.ts defines its public API. The workspace builds distribution archives under dist/richtext-core. Contracts and limits
Without explicit options, validateDocument may keep references to canonical subtrees the validator produced earlier. The validator records their origin privately, freezes their data deeply, and checks their size and depth. External objects still go through validation, even if frozen. Repeated calls may return the same object with identical normalized values and JSON v1 representation.
Passing any explicit options object, including {}, runs a full traversal that applies custom limits and the link policy and reports diagnostics. The validator handles shared and overlapping subtrees while preserving the distinction between copying and moving. Performance measurements
