Skip to content

Commit 143ced0

Browse files
committed
fix regexp
1 parent f48d866 commit 143ced0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ import devPropertiesWithoutUnitsRegExp from './devPropertiesWithoutUnitsRegExp'
66
import TokenStream from './TokenStream'
77

88
// Note if this is wrong, you'll need to change tokenTypes.js too
9-
const numberOrLengthRe = /^([+-]?(?:\d*\.)?\d+(?:[Ee][+-]?\d+)?)(?:px)?$/
10-
const numberOnlyRe = /^[+-]?(?:\d*\.\d*|[1-9]\d*)(?:[Ee][+-]?\d+)?$/
9+
const numberOrLengthRe = /^([+-]?(?:\d*\.)?\d+(?:e[+-]?\d+)?)(?:px)?$/i
10+
const numberOnlyRe = /^[+-]?(?:\d*\.\d*|[1-9]\d*)(?:e[+-]?\d+)?$/i
1111
const boolRe = /^true|false$/i
1212
const nullRe = /^null$/i
1313
const undefinedRe = /^undefined$/i

0 commit comments

Comments
 (0)