Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Update README.md

  • Loading branch information...
commit 55eed54f419be5a755733917f19527972ef08899 1 parent 8d6bba8
@Daniel15 authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 README.md
View
4 README.md
@@ -1,7 +1,7 @@
NamedRegExp
===========
-This is a very simple and tiny JavaScript library to add [named capturing groups](http://www.regular-expressions.info/named.html)
+This is a very simple and tiny JavaScript library to add support for [named capturing groups](http://www.regular-expressions.info/named.html)
to JavaScript's RegExp object. It does this by exposing a new class called `NamedRegExp` that
inherits functionality from the native RegExp object and adds additional functionality.
@@ -12,7 +12,7 @@ Usage
```javascript
var regexp = new NamedRegExp('Hello (?P<name>\\w+) from (?P<year>20[1-9][0-9])');
-var results = regexp.exec('Hello Daniel');
+var results = regexp.exec('Hello Daniel from 2012');
alert(results.name) // "Daniel"
alert(results.year) // "2012"
```
Please sign in to comment.
Something went wrong with that request. Please try again.