To enable plugins, python has the importlib.metadata library which allows you to do something like
for plugin in entry_points(group="my_module.plugin"):
do_something_with_plugin(plugin.name, plugin.load())
(originally this was available as pkg_resources.iter_entry_points. A package from setuptools. But it is now included in the standard library)
Is there a similar functionality in javascript?