-
Notifications
You must be signed in to change notification settings - Fork 43
import.meta.resolve consensus discussion #458
Comments
Once we decide on API and semantics, I'd love to build it in https://npmjs.com/resolve as well. |
I'll be rather busy in the next week as will several others I'm sure so we might want to setup a timeline to avoid this being under reviewed and/or just give a clear timeline when the discussion is over so that we don't merge too quickly after discussion ends. |
this is maybe related nodejs/node#31120 |
@frank-dspeed can you please elaborate with examples of using
|
@SMotaal my loader would simply extract all imports and pass them to import.resolve if needed |
i have a exra helper that i call resolvePath() // gets called with a import.meta.url returns path
export function resolvePath(url){
return urlToPath(url)
} i import that helper into any module and call it with the modules import.meta.url to retrive relativ path to current module |
I've just opened the PR in nodejs/node#31032 for
import.meta.resolve
support.This is something there have been browser discussions around for quite a while, so I've reached out to those working on this there on this feature to ensure that whatever is done here can align between the platforms.
Specifically, we don't want either Node.js or the browser shipping something the other won't want to implement.
The text was updated successfully, but these errors were encountered: