const d = function() {console.log(666666666);}d.f = () => {console.log(5);}d.f()console.log(d);
函数其实也是一个对象,也可以使用 .属性 的方式往函数里面添加属性,添加的属性当然也可以是一个函数。