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.

  • @wthit56OP
    link
    English
    13 months ago

    I got it working! Made my own wrapper for createPerchanceTree, that does this recursive loading at the same time. A touch hacky, as for whatever reason it seems running dynamic_import tries to get those imports? Or something? So I wrap that part in a try-catch everything else (seems to) work just fine.

    https://perchance.org/advanced-createperchancetree

    No problem if you want to take these ideas and work it into the engine itself by the way–all good if I can help improve the platform in my own way. 👍 @perchance