Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Using `x` flag with `RegExp`:
- new RegExp(`
- # A regular expression for date.
- (?<year>\\d{4})- # year part of a date
- (?<month>\\d{2})- # month part of a date
- (?<day>\\d{2}) # day part of a date
- `, 'x');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement