I want to structure object in es6 but not getting results.(我想在es6中构造对象,但没有得到结果。)
let animal ={
data:{
typee:{
title: "Cow",
legs:4
}
}
}
let {data:{typee:{title,legs}}}=animal;
now console.log(data)
giving output Error: data is not defined
.(现在console.log(data)
提供输出Error: data is not defined
。) What I am doing wrong ?(我做错了什么?)
ask by Ashwani Panwar translate from so