Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Problem from version5+ to Regex when using ReactNative Hermes engine #76

Closed
alimek opened this issue Jun 22, 2021 · 1 comment · Fixed by #80
Closed

Problem from version5+ to Regex when using ReactNative Hermes engine #76

alimek opened this issue Jun 22, 2021 · 1 comment · Fixed by #80

Comments

@alimek
Copy link

alimek commented Jun 22, 2021

Problem is in that line:

const matches = /(?<colorString>[a-f\d]{6}|[a-f\d]{3})/i.exec(hex.toString(16));

When generating hermes bytecode it is failing because Invalid regular expression: Quantifier has nothing to repeat

Some info here: facebook/hermes#89

I also think it may be related to https://github.com/facebook/jest/blob/master/packages/pretty-format/package.json and its pretty-format package.

@sindresorhus
Copy link
Member

This package targets Node.js 12. For any other platform/engine, you're on your own. We don't plan to add any workarounds for Hermes.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants