fix: 修复 slot 类型在 history 操作时被清空的 bug

This commit is contained in:
力皓 2021-06-07 19:44:16 +08:00
parent 0105365651
commit 1de26215b2

View File

@ -357,7 +357,7 @@ export function upgradePropConfig(config: OldPropConfig, collector: ConfigCollec
initialFn = (value: any, defaultValue: any) => {
// initialValue 为 true但 value 为 false / '' 等值,说明被关闭了
if (value === false || value === '') return value;
if (isJSBlock(value)) {
if (isJSBlock(value) || isJSSlot(value)) {
return value;
}
return {