I have code using spread(...)
and my jshint underlined it saying:
'object spread property' is only available in ES9 (use 'esversion: 9'). (W119) jshint(W119)
var morning = {
breakfast: "oatmeal",
lunch: "peanut and jelly",
eat() {
console.log("will eat later");
}
};
var dinner = "mac and chees";
var backpackingMeals = {
...morning,
dinner
};
console.log(backpackingMeals);
Try adding these comments before and after the line:
/*jshint -W119*/
//your line goes here
/*jshint +W119*/
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.