版权声明:任先阳 任 先 阳 任先 先阳,nvcc.cc、www.nvcc.cc、sbfox.com、www.sbfox.com https://blog.csdn.net/qq_39571197/article/details/83034211
迫不及待的尝试新特性,乱七八糟的入门demo
const box = {
weight: 2,
getWeight() { return this.weight; },
};
const { getWeight } = box;
box::getWeight();//等价于box.getWeight()
function add(val) { return this + val; }
console.log(box::getWeight()::add(5));//7