It creates objects for the import, but when accessing it it throws the error Cannot read properties of undefined (reading 'getSelf')
from line in the getter:
let moduleRoot = window.moduleSpace[moduleName].getSelf;
So it seems like it thinks it’s there, but it hasn’t actually loaded in at all.
Short-term, a more useful error message would be useful for creators. But ideally, it would actually load in the import when createPerchanceTree is called.
I just edited your demo page and tried it with my own chain of test imports and seems to work fine 👍
How’d you get it to work without throwing because it had stuff that wasn’t already imported?