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

Dynamically importing relative paths #8

Open
jpray opened this issue Apr 21, 2019 · 0 comments
Open

Dynamically importing relative paths #8

jpray opened this issue Apr 21, 2019 · 0 comments

Comments

@jpray
Copy link

jpray commented Apr 21, 2019

In comparing the dimport legacy importer with Chrome's native importer, I am noticing a discrepancy in how paths are resolved.

In chrome, I see the following happening...

Given the following structure:
/index.html
/foo/main.js
/foo/dynamic-component.js

if /foo/main.js has the following code

import('./dynamic-component.js');

Chrome loads the file fine. When testing in Firefox using the legacy importer it is looking for the file in /dynamic-component.js instead of /foo/dynamic-component.js and 404s. I haven't tested the module/nomodule versions to see if there is any difference with them.

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

1 participant