mysticatea/regexpp

Some questions about reusing this library

bd82 opened this issue · 3 comments

bd82 commented

Hello.

I'd like to reuse your library in a Parsing library I've authored.
I am currently using a regExp Parser that I've written myself
But your library seems of a higher quality and it would save me the trouble of maintaining my own regExp parser 😄.

Questions:

  1. Can this library be run in the browser? are there any limitations on bundling it for browser usage, including IE11 😢
  2. Why is node >= 6.5 needed?
  3. Are there any limitation or constraints I should be aware of?

Cheers.

Hi. Thank you for this issue!

  1. I'm sure that this library can work in browsers because https://eslint.org/demo/ includes this. You need to transpile (with Babel or something like) this library in order to run this libray in IE.
  2. This library is using ES2015 syntax. Node.js 6.5.0 is the first version which supports ES2015 enough. See detail: https://node.green/
  3. Nothing in particular, I think. Please tell me if you find bugs.
bd82 commented

Great.

I will experiment with this in regards to performance and refactoring my code to work with your AST.
I will also inspect if any performance regressions occur.

I also hope I will manage to bundle only a subset of this library (tree shacking) to reduce the bundle size and if everything works will have to specify node.js 6.5 is required for my library as well
But that is not a major problem because node.js 6.x is going EOF early next year.

bd82 commented

I will close this for now and update when I have new information.