Baike.dev
All toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
P

parsimmon

> 编程语言
Open source

A monadic LL(infinity) parser combinator library for javascript

1.3K stars0 likes2 views
WebsiteGitHub

About

A monadic LL(infinity) parser combinator library for javascript

!!! PARSIMMON IS CURRENTLY UNMAINTAINED !!!

Please contact @jneen if you would like to become the new maintainer.

Parsimmon

Original Authors: @jneen and @laughinghan

Previous Maintainer: @wavebeem

Parsimmon is a small library for writing big parsers made up of lots of little parsers. The API is inspired by parsec and Promises/A+.

Parsimmon supports IE7 and newer browsers, along with Node.js. It can be used as a standard Node module through npm (named parsimmon), or directly in the browser through a script tag, where it exports a global variable called Parsimmon. To download the latest browser build, use the unpkg version. For more information on how to use unpkg, see the unpkg homepage.

Code of Conduct

Everyone is expected to abide by the Contributor Covenant.

API Documentation

  • Full API documentation in API.md
  • Guide with additional questions
  • Tutorial by Max Tagher

Examples

See the examples directory for annotated examples of parsing JSON, Lisp, a Python-ish language, and math.

Common Functions

  • .createLanguage(parsers)
  • .string(string)
  • .regexp(regexp)
  • .seq(p1, p2, ...pn)
  • .sepBy(content, separator)
  • .alt(p1, p2, ...pn)
  • .whitespace
  • .index
  • parser.map(fn)
  • parser.node(name)
  • parser.skip(otherParser)

Questions

Feel free to ask a question by filing a GitHub Issue. I'm happy to help point you in the right direction with the library, and hopefully improve the documentation so less people get confused in the future.

Contributing

Contributions are not just pull requests.

Issues clearly describing bugs or confusing parts of Parsimmon are welcome! Also, documentation enhancements and examples are very desirable.

Feeling overwhelmed about contributing? Open an issue about what you want to contribute and I'm happy to help you through to completion!

Performance

Thanks to @bd82 we have a good benchmark comparing Parsimmon CPU performance to several other parser libraries with a simple JSON parser example.

Fantasyland

Parsimmon is also compatible with fantasyland. It implements Semigroup, Apply, Applicative, Functor, Chain, and Monad.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

JavaScript

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言