Created
August 14, 2018 23:14
-
-
Save alexko30/54d8e7ba75a3d3ee4b4179ab2bd032ab to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
test(startValue) { // rgb(255, 0, 0) | |
return startValue.indexOf('rgb') >= 0 | |
|| startValue.indexOf('#') >= 0 | |
|| startValue.indexOf('hsl') >= 0 | |
|| (typeof startValue === 'string' && colorString.get.rgb(startValue)); // true | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment