bnb is semver v0, but unlikely to change much. It should be a stable platform for development.
With relatively little code and no build step, you can get a proper parser prepared for the language or input of your choice. A few functions and methods, paired with a bit of regular expression experience, is all you need.
bnb has zero dependencies and is about 1.5 KB minified and gzipped (about 12 KB raw compiled JS from TypeScript source).
npm i bread-n-butter
If you are using ES modules through TypeScript/webpack and npm:
import * as bnb from "bread-n-butter";
If you are using Node.js require:
const bnb = require("bread-n-butter");
If you are using ES modules natively in the browser without npm, download the ES modules build:
import * as bnb from "./bread-n-butter.js";
# Getting Started
bnb is a parser combinator library. You can build up complex parsers using combinators (functions that take parsers and return parsers).
Check out the tutorial for help getting started.
See the examples on GitHub for how to implement various language parsers using bnb.
Read the full API documentation for more information about every function.
Also, if you are using Visual Studio Code and have installed bnb through npm, you should get automatic API completion with inline documentation so you can save time by never leaving your editor.