Concepts for JavaScript developers to know
github.com
github.com
new Error().stack
That is a de facto standard for creating a call stack anywhere without interruption.There were several things on that list you never need. 14-18 is for OOP which is fully optional in the language.
Despite the warning at the top of the article the convention is widely available cross browser and in terminal runtimes like Node.
I wish this was more widely understood (that's it's merely a pattern, not an inevitability), so much OOP code is just bags of arbitrary stuff. It's not an inherently bad pattern, just often misused.
Can you guess what my biggest problem with OOP is?
[1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
[2]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
[3]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
For example, if you use Symbols as keys in an object, Object.keys() or for...of/in will NOT return/iterate over those keys. You have to use Object.getOwnPropetySymbols()...