Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gaku-sei/ls-regularity
https://github.com/gaku-sei/ls-regularity
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/gaku-sei/ls-regularity
- Owner: gaku-sei
- Created: 2013-11-08T07:28:24.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2013-11-12T03:06:45.000Z (about 11 years ago)
- Last Synced: 2024-11-05T13:12:44.302Z (3 months ago)
- Language: LiveScript
- Size: 102 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
### Regularity LS
Conversion of the ruby library [Regularity](https://github.com/andrewberls/regularity "Regularity").
```LiveScript
require! regularity.RegularityRegularity!
.start-with 3 \digits
.then \-
.then 2 \letters
.maybe \#
.one-of <[a b]>
.between [2 4] \a
.end-with \$
.regex!
```Will return this regexp:
```JavaScript
/^[0-9]{3}-[A-Za-z]{2}#?[a|b]a{2,4}\$$/
```