Skip to content

Commit

Permalink
refactor: use PropertyKey instaed of key list (#728)
Browse files Browse the repository at this point in the history
  • Loading branch information
EdamAme-x authored Sep 29, 2024
1 parent caec3cf commit 4821112
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import type { EditableConfig } from './interface';
* We trade Map as deps which may change with same value but different ref object.
* We should make it as hash for deps
* */
export function stringify<K extends string | number | symbol, V>(obj: Record<K, V> | Map<K, V>) {
export function stringify<K extends PropertyKey, V>(obj: Record<K, V> | Map<K, V>) {
let tgt: Record<K, V>;

if (obj instanceof Map) {
Expand Down

0 comments on commit 4821112

Please sign in to comment.