es6 · ES6 Basics
What will this function return?
(function() {
if (false) {
let f = { g() => 1 };
}
return typeof f;
})()Answers
- Undefined
- "object"
- "function"
- Error
es6 · ES6 Basics
(function() {
if (false) {
let f = { g() => 1 };
}
return typeof f;
})()