(function(){请注意,该函数没有名称,也没有存储在变量中。函数表达式末尾的两个括号()会立即执行或调用它。此模式称为
console.log(“Chirp,chirp!”);
})(); //这是一个立即执行的匿名函数表达式
//输出“Chirp,chirp!”立即
immediately invoked function expression
或IIFE
。 makeNest
并删除它的调用,所以它是一个匿名的immediately invoked function expression
( IIFE
)。