Message from JavaScript discussions

November 2017

— It slows down all other identifiers

— 

var thing = { test: 123 };
with (thing) {
console.log(test);
}


equal to

var thing = { test: 123 };
console.log(thing.test);

— Ohhh that explains what unscopables are

— Heh

— Yeah

— TIL

— with seems like it could be useful... but not for any of the reasons on the MDN page lol

— "less filesize" is a ridiculous reason to use with imo, we have uglifiers for that

— Learned something else too, you can re-throw errors out of catch blocks

— IRL prod code:

— 

} catch (error) {
if ("error" in strategy) {
// Run `error` if an error occured;
var errorReturnValue = strategy.error(state, error);
if (errorReturnValue !== undefined) {
returnValue = errorReturnValue;
}
} else {
throw error;
}
}

Message permanent page

— WAIT WHAT THE HELL