Open andersstorhaug opened 2 years ago
A little more info, I can get this library that's dependent on IxJS to work through JSPM which utilizes import maps (+shim). This seems to show that it is indeed IxJS's package.json
that makes it incompatible with ESM-based CDNs, such as Skypack, esm.sh, JsDelivr with /+esm
.
I'm hoping that a simple change to package.json
would allow for these CDNs to be used, but, I'm a little hesitant to attempt a PR myself to that end, given the multiple builds that IxJS has.
We should be able to update the published package.json to be compatible. I'll add it to my mental todo list.
I am attempting to use a package via Skypack that depends on IxJS.
This package understandably depends on the main
ix
package, but that doesn't work with Skypack because as far as I can tell, IxJS'spackage.json
doesn't have any ESM properties.If I try to use the
ix
package directly via Skypack withimport { from } from "https://cdn.skypack.dev/ix/iterable";
this also doesn't work, because an ESM isn't exported. However, usingimport { from } from "https://cdn.skypack.dev/@reactivex/ix-es5-esm";
does work.Wondering how this could be resolved -- should the library instead depend on
@reactivex/ix-es5-esm
/@reactivex/ix-esnext-esm
, or is it possible to make changes to IxJS'spackage.json
so that Skypack works correctly with the mainix
package?