I just discovered this sweet library by @djkelleher: https://github.com/djkelleher/dynamic-imports. It could be used to replace the custom code currently used for plugin loading. 💯