Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Loading aurelia-loader-default without System #9

Closed
jods4 opened this issue Jun 9, 2015 · 3 comments
Closed

Loading aurelia-loader-default without System #9

jods4 opened this issue Jun 9, 2015 · 3 comments

Comments

@jods4
Copy link
Contributor

jods4 commented Jun 9, 2015

The codebase from Aurelia makes extensive use of System api. At the same time, it's supposed to work without it, e.g. in a requirejs runtime. To that effect, aurelia-loader-default installs a very thin polyfill for System when it's missing (basically delegating to require).

The problem is that aurelia-bootstrapper loads aurelia-loader-default dynamically, with a call to System.import, which is of course impossible at that point.

It's a kind of chicken-and-egg problem. I don't know what was the thinking behind dynamically loading aurelia-loader-default. It seems to me the easiest fix is to import it statically.

I worked around this problem by making sure that aurelia-loader-default is loaded before aurelia-bootstrapper is, but that feels wrong. It feels like a magic incantation whereas it should be a basic dependency of the bootstrapper.

@EisenbergEffect
Copy link
Contributor

Already fixed this and deployed the release. jspm update the bootstrapper and it should be fixed.

@npelletm
Copy link

npelletm commented Jun 9, 2015

cf aurelia/framework#110 that fix it
too slow... ;-)

@jods4
Copy link
Contributor Author

jods4 commented Jun 9, 2015

Fixed 6 hours before I reported it? That was fast! ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants