snek

Results 463 comments of snek

@jkrems i think cjs loader hooks are outside the realm of our design. cjs can only deal with local files and it uses filenames, not urls. Providing resource content is...

@bmeck i don't doubt it can be done, i'm just less convinced it makes sense to include with the esm loader hooks given the large differences in the systems.

the first one is already possible with our current design (not including cjs). the second one is interesting and should probably exist, but it is unlikely that a cjs version...

You shouldn't use import() to provide the unmodified target. In this case, you should know in the resolve hook whether you want to apm something or not. In any case,...

at the moment there's no way to load the original module, at least not easily. hooks are still a WIP

@guybedford its not that it "doesn't work", more that it behaves oddly. You've resolved `X` to `Y` and then you ask for `X` again while in the middle of loading...

@guybedford its a delicate situation. perhaps we should have a special import exposed to each hook that bypasses that specific hook. there are still a lot of open questions.

we could also just get rid of `type: module`, assuming we want people to depend less on package.json magic, not more

I definitely didn't intend to start any arguments about extensions, I was just hoping to get in some ideas about various directions to go with ecosystem feedback. best to think...

we shouldn't ever have a case where a file will run more than once.