-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add new XRegExp backend #1
Comments
@fileformat I see you've added XRegExp support in commit e2333b8, and that the XRegExp version of the tester is now live. That's awesome! A few issues to report about the XRegExp support, though. Not specific to XRegExp:
Specific to XRegExp:
Feature requests, specific to XRegExp:
The full list of changes is currently in the roadmap. The release of v3.0.0-final might be delayed for a while since I need to focus on other projects, which is why I think it makes sense to go ahead and upgrade early. Flag If you have any questions, I'd be happy to help! |
Are you interested in adding an XRegExp backend (separate from the standard JavaScript backend)? It should be easy to do, since you already support JavaScript with Node.js. You'd probably just need to include XRegExp (
var XRegExp = require('xregexp').XRegExp;
, after installing with npm), add checkboxes for XRegExp's three nonnative flags (s
,x
, andn
), and use XRegExp.replace/exec/test/split rather than the native methods, for testing.Actually, since XRegExp compiles to native regexes, you don't even need to use
XRegExp.exec
/test
/split
. You do needXRegExp.replace
, to use XRegExp's replacement text syntax. You'd probably also want to useXRegExp.exec
, so that you get named backreferences on the result array.If you have any questions or run into any issues, I'd be happy to help.
The text was updated successfully, but these errors were encountered: