自执行函数如何传递参数

1 (function( abc ) {
2 console.log(abc) // ==> 1231
3 })( 1231 );
4 
5 (function(window){
6 console.log(window) // ==> Window {speechSynthesis: SpeechSynthesis, caches: CacheStorage, localStorage: Storage, sessionStorage: Storage, webkitStorageInfo: DeprecatedStorageInfo…}
7 })(window)
原文地址:https://www.cnblogs.com/ndh074512/p/14772890.html