var f = function() { console.log('I am outside!'); } (function s() { var f = function() { console.log('I am inside!'); } f(); }()); f(); "C:\Program Files\JetBrains\IntelliJ IDEA 2018.1.4\bin\runnerw.exe" C:\nodejs\node.exe C:\path\to\projects\test\src\test\test.js I am inside! C:\path\to\projects\test\src\test\test.js:8 f(); I am outside! ^
TypeError: f is not a function at Object.<anonymous> (C:\path\to\projects\test\src\test\test.js:8:1) at Module._compile (internal/modules/cjs/loader.js:689:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) at Module.load (internal/modules/cjs/loader.js:599:32) at tryModuleLoad (internal/modules/cjs/loader.js:538:1) at Function.Module._load (internal/modules/cjs/loader.js:530:3) at Function.Module.runMain (internal/modules/cjs/loader.js:742:12) at startup (internal/bootstrap/node.js:283:19) at bootstrapNodeJSCore (internal/bootstrap/node.js:743:3)</anonymous>
Process finished with exit code 1
