File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change 1
1
VerbalExpressions v0.1
2
2
=====================
3
3
4
- ## JavaScript Regular expressions made easy
5
- VerbalExpressions is a JavaScript librarty that helps to construct hard regular expressions.
4
+ ## JavaScript Regular Expressions made easy
5
+ VerbalExpressions is a JavaScript library that helps to construct difficult regular expressions.
6
6
7
7
## How to get started
8
8
9
9
Include the library and you're good to go!
10
10
``` HTML
11
- <script type = " text/javascript " src =" VerbalExpressions.js" ></script >
11
+ <script src =" VerbalExpressions.js" ></script >
12
12
```
13
13
14
14
## Examples
15
15
16
- Here's a couple of simple examples to give an idea of how VerbalExpressions work :
16
+ Here's a couple of simple examples to give an idea of how VerbalExpressions works :
17
17
18
- ### Testing if we have valid URL
18
+ ### Testing if we have a valid URL
19
19
20
20
``` javascript
21
21
// Create an example of how to test for correctly formed URLs
@@ -31,7 +31,7 @@ var tester = VerEx()
31
31
// Create an example URL
32
32
var testMe = " https://www.google.com" ;
33
33
34
- // Use RegExp object's native test() - function
34
+ // Use RegExp object's native test() function
35
35
if ( tester .test ( testMe ) ) alert ( " We have a correct URL " ); // This output will fire
36
36
else alert ( " The URL is incorrect" );
37
37
Original file line number Diff line number Diff line change @@ -92,10 +92,10 @@ window.VerbalExpression = (function(){
92
92
return ( this ) ;
93
93
} ,
94
94
95
- // We try to keep the syntax ass
95
+ // We try to keep the syntax as
96
96
// user-friendly as possible.
97
97
// So we can use the "normal"
98
- // behaviour to split the "scentences "
98
+ // behaviour to split the "sentences "
99
99
// naturally.
100
100
then : function ( value ) {
101
101
value = this . sanitize ( value ) ;
@@ -118,7 +118,7 @@ window.VerbalExpression = (function(){
118
118
return ( this ) ;
119
119
} ,
120
120
121
- // Any character any times
121
+ // Any character any number of times
122
122
anything : function ( ) {
123
123
this . add ( "(.*)" ) ;
124
124
return ( this ) ;
You can’t perform that action at this time.
0 commit comments