Command-line interface for the regexp-tree library (v0.0.21). Parses, optimizes, and transpiles JavaScript/ECMAScript regular expressions, producing ASTs with loc support, NFA/DFA transition tables, and compatibility transpilation. Unlike regex libraries that only match or replace, regexp-tree-cli operates at the AST level for transformations and analysis. Primarily a CLI tool, but can be used programmatically via the regexp-tree package. Last stable release is v0.0.21; development is infrequent but the underlying regexp-tree library is more actively maintained.
npm install regexp-tree-cliNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Install CLI globally, parse a regex with location and optimizer output.
Always include slashes: regexp-tree-cli -e '/pattern/flags'
Use regexp-tree's compat-transpiler directly for full support.
Use `--table` output to get formatted tables for NFA/DFA.
Use the CLI from the terminal, or import 'regexp-tree' for programmatic use.
Wrap in slashes: -e '/ /' or provide a valid pattern.
Ensure the regex is valid and pattern is enclosed in slashes.