We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 44fb67b commit e9ca7abCopy full SHA for e9ca7ab
src/util/dataTypes.js
@@ -3,11 +3,12 @@ import { parseBoxShadowValue } from './parseBoxShadowValue'
3
import { splitAtTopLevelOnly } from './splitAtTopLevelOnly'
4
5
let cssFunctions = ['min', 'max', 'clamp', 'calc']
6
+let IS_CSS_FN = new RegExp(`^(${cssFunctions.join('|')})\\(.*\\)`)
7
8
// Ref: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Types
9
10
function isCSSFunction(value) {
- return cssFunctions.some((fn) => new RegExp(`^${fn}\\(.*\\)`).test(value))
11
+ return IS_CSS_FN.test(value)
12
}
13
14
// This is not a data type, but rather a function that can normalize the
0 commit comments