14 ms·
Are there other JS interfaces that use the global symbol pattern? ie [Symbol.dispose] or is this some new approach? I get it but haven't really seen that sort
by dmix 3y ago
Are there other JS interfaces that use the global symbol pattern? ie [Symbol.dispose] or is this some new approach?
I get it but haven't really seen that sort of thing before.
- dvlsg 3y agoYeah, there's a number of cases that use the Symbol pattern. They're all relatively new, but that's at least in part due to Symbols themselves being relatively new. Symbol.iterator comes to mind as a decent example.
- Me1000 3y agoYou can find a more complete list of "well-known symbols" here: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
- dmix 3y agoThank you!