mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-14 04:48:40 -09:00
6 lines
158 B
JavaScript
6 lines
158 B
JavaScript
|
|
function isHexColor(color) {
|
||
|
|
return /(^#[0-9A-F]{6,8}$)|(^#[0-9A-F]{3}$)/i.test(color); // https://regex101.com/
|
||
|
|
}
|
||
|
|
|
||
|
|
module.exports.isHexColor = isHexColor;
|