feat(core): keep-alive
This commit is contained in:
@@ -73,7 +73,7 @@ export const PublicInstanceProxyHandlers: ProxyHandler<any> = {
|
||||
propsProxy,
|
||||
accessCache,
|
||||
type,
|
||||
user
|
||||
sink
|
||||
} = target
|
||||
// fast path for unscopables when using `with` block
|
||||
if (__RUNTIME_COMPILE__ && (key as any) === Symbol.unscopables) {
|
||||
@@ -128,8 +128,8 @@ export const PublicInstanceProxyHandlers: ProxyHandler<any> = {
|
||||
return instanceWatch.bind(target)
|
||||
}
|
||||
}
|
||||
if (hasOwn(user, key)) {
|
||||
return user[key]
|
||||
if (hasOwn(sink, key)) {
|
||||
return sink[key]
|
||||
} else if (__DEV__ && currentRenderingInstance != null) {
|
||||
warn(
|
||||
`Property ${JSON.stringify(key)} was accessed during render ` +
|
||||
@@ -157,7 +157,7 @@ export const PublicInstanceProxyHandlers: ProxyHandler<any> = {
|
||||
warn(`Attempting to mutate prop "${key}". Props are readonly.`, target)
|
||||
return false
|
||||
} else {
|
||||
target.user[key] = value
|
||||
target.sink[key] = value
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user