Hi Calla,
I think your approach does seem like the only way to ensure that everything has loaded. The challenge, as you've discovered, is how to get it to play nicely with the static pipeline on fullstack. To get started, you might find the material linked from this wiki page useful:
The logistration factory is loaded using this Mako function that behaves differently in fullstack:
What happens is that the factory and all of its dependencies are bundled into a single JavaScript file by RequireJS Optimizer (r.js), and then the resulting file is included as a script on the page rather than it being loaded asynchronously via RequireJS. From the sound of your error, it appears that you are requiring the factory before the bundle has been loaded, so your code ends up trying to load it via RequireJS. Then when the bundle loads, it throws an error because the code has already been loaded, which the r.js-optimized code doesn't expect.
It seems that what you need is to both have a dependency upon the factory *and* have your file loaded after the bundle. The factory is loaded in the js_extra block and I don't see a hook for you to ensure that your file is loaded afterwards:
If you are comfortable modifying the platform, you might look at whether the logistration_factory can be loaded earlier, so that everything loaded in the js_extra block can rely upon the bundle being loaded in fullstack. Another option would to be introduce yet another block, but that to me seems more confusing. IMO the js_extra block is meant precisely for the kind of thing you are doing.
I hope this helps get you started. Let me know if I can help any more. If you want to continue this discussion in real time, you can use the #front-end channel in Slack (I'm @andya).
Thanks,
- Andy