Skip to content
asmblahPublic

About

PCRE emulation for JavaScript

Resources

Stars

0 stars

Watchers

1 watching

Forks

Repository files navigation

PCREmu

Build Status

PCRE emulation for JavaScript.

Usage

Example usage if consuming from outside an ES module:

$ npm i pcremu
const pcremu = require('pcremu').default;

// Create a matcher for your regex.
const matcher = pcremu.compile('^something');

// Match the regex against your input string.
const match = matcher.matchOne('something here');

console.log(match.getCaptureCount()); // Outputs "1".
console.log(match.getLength()); // Outputs "9" (the length of the word "something").

See also

About

PCRE emulation for JavaScript

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages