Subscribe on changes!

Unhandled error during execution of scheduler flush.

avatar
Aug 18th 2021

Version

3.2.4

Reproduction link

[https://sfc.vuejs.org/#eyJBcHAudnVlIjoiIiwiRm9sZGVyQXJyb3cudnVlIjoiPHRlbXBsYXRlPlxuLi4uXG48L3RlbXBsYXRlPlxuXG48c2NyaXB0IGxhbmc9XCJ0c1wiPlxuaW1wb3J0IHsgZGVmaW5lQ29tcG9uZW50fSBmcm9tICd2dWUnO1xuZXhwb3J0IGRlZmF1bHQgZGVmaW5lQ29tcG9uZW50KHtcbiAgcHJvcHM6e1xuICAgIGRhdGFzOntcbiAgICAgIHR5cGU6T2JqZWN0LFxuICAgICAgZGVmYXVsdDogZnVuY3Rpb24gKCkge1xuICAgICAgICByZXR1cm4ge3RpdGxlOlwiXCIsIHRyZWVEYXRhczpbXX1cbiAgICAgIH1cbiAgICB9XG4gIH0sXG4gIHNldHVwKHByb3BzKSB7XG4gICAgICBsZXQgZGF0YXMgPSAocHJvcHMgYXMgYW55KS5kYXRhcztcbiAgICAgIGxldCByb290VHJlZSA9IGRhdGFzLnRyZWVEYXRhcztcbiAgICAgIGxldCBoaWVyYXJjaHk6bnVtYmVyO1xuICAgICAgaWYocm9vdFRyZWUuaGllcmFyY2h5PT11bmRlZmluZWQpe1xuICAgICAgICBoaWVyYXJjaHkgPSAwO1xuICAgICAgfWVsc2V7XG4gICAgICAgIGhpZXJhcmNoeSA9IHJvb3RUcmVlLmhpZXJhcmNoeVxuICAgICAgfVxuXG4gICAgICBsZXQgc3VidHJlZUFycmF5ID0gW107XG4gICAgICBpZihyb290VHJlZS50cmVlRGF0YXMubGVuZ3RoIT0wKXtcbiAgICAgICAgc3VidHJlZUFycmF5ID0gcm9vdFRyZWUudHJlZURhdGFzOyAgXG4gICAgICAgIHN1YnRyZWVBcnJheVtcImhpZXJhcmNoeVwiXSA9IGhpZXJhcmNoeSArMTsgXG4gICAgICB9XG4gICAgcmV0dXJue1xuICAgICAgICBoaWVyYXJjaHksXG4gICAgIC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ICAgICB9XG4gICAgcmV0dXJue1xuICAgICAgICBoaWVyYXJjaHksXG4gICAgICAgIHJvb3RUcmVlLFxuICAgICAgICBhcnJvd19zcmMsXG4gICAgICAgIHN1YnRyZWVBcnJheVxuICAgIH1cbiAgfSxcbn0pO1xuPC9zY3JpcHQ XG4ifQ==)

Steps to reproduce

在父组件中:

let datas1 = {title:"标题1",treeDatas:[ {title:"标题2-1",treeDatas:[]}, {title:"标题2-2",treeDatas:[ {title:"标题2-2-1",treeDatas:[]}, {title:"标题2-2-2",treeDatas:[ {title:"标题2-2-2-1",treeDatas:[ {title:"标题2-2-2-1-1",treeDatas:[ {title:"标题2-2-2-1-1-1",treeDatas:[ {title:"标题2-2-2-1-1-1-1",treeDatas:[ {title:"标题2-2-2-1-1-1-1-1",treeDatas:[]}, ]}, ]}, ]}, ]}, ]}, ]}, {title:"标题2-3",treeDatas:[ {title:"标题2-3-1",treeDatas:[]}, {title:"标题2-3-2",treeDatas:[ {title:"标题2-3-2-1",treeDatas:[]}, {title:"标题2-3-2-2",treeDatas:[ {title:"标题2-3-2-2-1",treeDatas:[]}, {title:"标题2-3-2-2-2",treeDatas:[]}, {title:"标题2-3-2-2-3",treeDatas:[]}, ]}, {title:"标题2-3-2-3",treeDatas:[ {title:"标题2-3-2-3-1",treeDatas:[]}, {title:"标题2-3-2-3-2",treeDatas:[]}, ]}, {title:"标题2-3-2-4",treeDatas:[]}, ]}, ]}, {title:"标题2-4",treeDatas:[]}, {title:"标题2-5",treeDatas:[ {title:"标题2-5-1",treeDatas:[]}, {title:"标题2-5-2",treeDatas:[]}, {title:"标题2-5-3",treeDatas:[]}, {title:"标题2-5-4",treeDatas:[]}, ]}, {title:"标题2-6",treeDatas:[]}, ]};

在子组件中: props:{ datas:{ type:Object, default: function () { return {title:"", treeDatas:[]} } } }, let datas = (props as any).datas;

let rootTree = datas.treeDatas;

subtreeArray = rootTree.treeDatas; 这个版本的vue无法正确在子组件中获得被传入的对象(Object)型数据。

What is expected?

datas.treeDatas应该获取父组件传入的datas对象中的 treeDatas数组

What is actually happening?

这个版本的vue无法正确在子组件中获得被传入的对象(Object)型数据。

avatar
Aug 18th 2021

link is broken

avatar
Aug 18th 2021

Open a new issue with a working link and the steps in English, please