fix: 兼容vision版本

This commit is contained in:
荣彬 2020-12-15 14:24:08 +08:00
parent ae37a02d62
commit bfc9d68d00

View File

@ -21,13 +21,13 @@ export function compatibleReducer(props: any) {
}, },
}; };
} }
if (isJSExpression(props) && !props.events) { // if (isJSExpression(props) && !props.events) {
return { // return {
type: 'variable', // type: 'variable',
value: props.mock, // value: props.mock,
variable: props.value, // variable: props.value,
}; // };
} // }
const newProps: any = {}; const newProps: any = {};
Object.entries<any>(props).forEach(([key, val]) => { Object.entries<any>(props).forEach(([key, val]) => {
newProps[key] = compatibleReducer(val); newProps[key] = compatibleReducer(val);