-
Notifications
You must be signed in to change notification settings - Fork 12
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
Library seems to confuse skypack CDN #14
Comments
Some progress on this: UCAN = await import("https://cdn.skypack.dev/ucans")
UCAN.publicKeyBytesToDid(new Uint8Array([1, 2, 3]), "rsa") |
Skypack transforms an import of uint8arrays into import require$$0 from "/-/[email protected]/dist=es2019,mode=imports/optimized/uint8arrays.js"; And they transform the source uint8arrays module ( export {compare} from "./uint8arrays/compare.js";
export {concat} from "./uint8arrays/concat.js";
export {equals} from "./uint8arrays/equals.js";
export {fromString} from "./uint8arrays/from-string.js";
export {toString} from "./uint8arrays/to-string.js";
export {xor} from "./uint8arrays/xor.js";
import "./common/bases-af280048.js";
import "/-/[email protected]/dist=es2019,mode=imports/optimized/multiformats/basics.js";
export default null; I have no idea why it's Not sure what we can do about this. This seems like an issue with skypack. I've submitted an issue on their repository. |
We could make it easier for skypack by also bundling ESM, but that's just my hypothesis at this point. |
Yeah sadly we also had not so great experience with skypack things working on one version and stopping in the other. In our case it was one of the dependencies that had issues, but sadly I don’t know of a good way to identify the problems |
From context, is this a |
Maybe this could be re-framed to make it possible to load this lib on observable (and other ESM native runtimes) ? I might also give this a go if I find some time to do so |
I was trying to use this library in observable snippet and run into issue, it seems that something is confusing skypack CDN resulting in broken library. Here is the link to an example https://observablehq.com/@protocol/ucan-skypack-problem
The text was updated successfully, but these errors were encountered: