kach / nearley

📜🔜🌲 Simple, fast, powerful parser toolkit for JavaScript.
https://nearley.js.org
MIT License
3.57k stars 231 forks source link

unparse.js: fix UMD header for browser compatibility. #641

Open seansfkelley opened 10 months ago

seansfkelley commented 10 months ago

The existing file uses a mix of UMD and CommonJS for dependencies. This moves both dependencies to UMD so it can be dropped into a browser.

Note that randexp does ship a browser-compatible bundle, but only minified, and it exports under the name RandExp, not randexp.