TLDR
Use of the with statement is discouraged, but it is important to understand how it works. Using with can make long pieces of code easier to read due to the removal of long accessor paths. The danger or potential bugs due to ambiguity isn’t worth it. There is an argument to be made that code will be smaller and easier to send to the browser by using ‘with’ statements. While true, the gains are negligible, especially when compared to what minified code can do.via the TL;DR App
no story
Written by wagslane | Founder of Boot.dev.
Whining about coding sins since 2011. Committing coding sins for the same.