EdgeJS Parser is a specialized JavaScript library designed for parsing HTML and EdgeJS templating syntax, returning an Abstract Syntax Tree (AST). Currently at version 0.2.19, it is built upon the Chevrotain parsing toolkit. Its development is specifically tailored towards the creation of a Prettier plugin for EdgeJS templates, which implies it may not encompass all potential parsing needs or edge cases outside of that particular use-case. As a 0.x.x release, the API may still be subject to changes before a stable 1.0 version. While a formal release cadence isn't specified, updates are likely driven by the needs of its primary Prettier integration.
Verified import paths — ran on the pinned version, not inferred.
This package is an ES Module (`'type': 'module'`). CommonJS `require()` syntax is not supported and will result in a runtime error. Ensure your project is configured for ESM.
This quickstart demonstrates how to install `edgejs-parser` and use its default export to parse a simple EdgeJS template into an Abstract Syntax Tree (AST), including basic error handling for malformed input.
Breaking-change detection hasn't run for this library yet.
CVE tracking and dependency tree are planned for a later release.