Thanks, when I was working on a particularly convoluted React codebase, I realized that it's better to pass dependencies into modules rather than importing them and, when I looked around to see what prior art there was to this idea, I came across https://gbracha.blogspot.com/2009/06/ban-on-imports.html
It is worth asking on the forum to see if there is some exisiting code to show this in practice.