We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 622d042 commit 527c2c8Copy full SHA for 527c2c8
packages/reactivity/src/index.ts
@@ -22,7 +22,8 @@ export {
22
shallowReadonly,
23
markRaw,
24
toRaw,
25
- ReactiveFlags
+ ReactiveFlags,
26
+ DeepReadonly
27
} from './reactive'
28
export {
29
computed,
packages/reactivity/src/reactive.ts
@@ -74,7 +74,7 @@ export function shallowReactive<T extends object>(target: T): T {
74
75
type Primitive = string | number | boolean | bigint | symbol | undefined | null
76
type Builtin = Primitive | Function | Date | Error | RegExp
77
-type DeepReadonly<T> = T extends Builtin
+export type DeepReadonly<T> = T extends Builtin
78
? T
79
: T extends Map<infer K, infer V>
80
? ReadonlyMap<DeepReadonly<K>, DeepReadonly<V>>
0 commit comments