Namespaced Events
westonganger opened this issue · comments
I would like to know how to do something similar to namespaced events without jquery.
The reason this came up is that someone asked me to translate my plugin from jquery to vanilla. And I thought this might be fun. However namespaced events seems to be a totally non-standard thing in vanilla.
I have searched all around the web and the solutions were all wild or very unpopular.
Top few things I seen on the web after digging for too long
- Simple named function approach: https://stackoverflow.com/a/30801047/3068360
- Old but popular library: https://github.com/fat/bean
I wish this website could have given me a fairly standard answer to this.