Skip to content

Commit 4a6ded3

Browse files
committed
fix(system): fix caching issue with value with different types
1 parent af10d59 commit 4a6ded3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/system/src/style.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ export const themeGetter = <T = any>({
6464
if (!string(value) && !num(value) && value !== true) {
6565
return res as CSSScalar
6666
}
67-
const cacheKey = `${value}-${defaultValue}`
67+
const cacheKey = `${typeof value}-${value}-${defaultValue}`
6868
const cache = getCache<CSSScalar>(props.theme, `__themeGetter${id}`)
6969
if (cache.has(cacheKey)) return cache.get(cacheKey)
7070

0 commit comments

Comments
 (0)