0.1.0 • Published 7 years ago

miam v0.1.0

Weekly downloads
1
License
BSD-3-Clause
Repository
github
Last release
7 years ago

Miam • JS

miam.js is a parser combinator framework written in TypeScript. It is highly inspired by the excellent nom project. A special focus is brough on the type system to provide as much safety as possible, and to avoid consuming too much memory. Thus, the goal of miam.js is to provide a safe and relatively fast framework to build parsers.

miam.js is written in TypeScript, a language that compiles into JavaScript.

Features

  • Zero-copy: The parsers do not copy the string being analysed despite the fact that they are all pure,
  • Safe parsing: We commit to bring as much safety as possible regarding the current tooling and languages we have. All means (like type system) are used to provide a safe framework to develop new parsers,
  • Speed: No benchmark yet, but we hope that our approach with zero-copy will help to be fast,
  • Lightweight: All the type system disappears at compile-time (from TypeScript to JavaScript); the resulting files are small (≈5Kb).

List of parsers

Example

See the examples/ directory for some examples.

The test/unit/ directory contains a nice overview of the API too.

Status

Still under development. Please don't use it right now :-). API is under stabilisation.