is-hexcolor
Check that given value is valid hex color, using
hex-color-regex
- the best regex for matching hex color values
Install
npm i is-hexcolor --save
npm test
Usage
For more use-cases see the tests
var isHexcolor = //=> true //=> true //=> false //=> false //=> false //=> false //=> false //=> false //=> false //=> false
Related
- copyright-regex: Regex for matching and parsing copyright statements.
- github-short-url-regex: Regular expression (Regex) for matching github shorthand (user/repo#branch).
- hex-color-regex: The best regular expression (regex) for matching hex color values from string.
- mentions-regex: 100% twitter compatible
@mentions
regex! Regular expression for matching@username
mentions, as used on twitter, facebook, github, etc. - todo-regex: Regular expression for matching TODO statements in a string.
Contributing
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
But before doing anything, please read the CONTRIBUTING.md guidelines.