fix: 兼容事件绑定

This commit is contained in:
mario.gk 2020-07-17 14:53:21 +08:00
parent caf9915382
commit f4c07afba3
2 changed files with 5 additions and 1 deletions

View File

@ -152,7 +152,7 @@ function compatiableReducer(props: any) {
}
}
// 为了能降级到老版本,建议在后期版本去掉以下代码
if (isJSExpression(val)) {
if (isJSExpression(val) && !val.events) {
val = {
type: 'variable',
value: val.mock,

View File

@ -11,6 +11,10 @@ export interface JSExpression {
*
*/
mock?: any;
/**
* extTypeevents
*/
[key: string]: any;
}
export interface JSSlot {