Open ThomasLuuu opened 1 year ago
There's no main
entry in the latest version of the package, it instead uses exports
:
https://github.com/digitalbazaar/did-method-key/blob/main/package.json#L21
Are you using an older version? If so, please try upgrading to the latest to see if it resolves your problem.
I'm using the latest version of the package. "@digitalbazaar/did-method-key": "^3.0.0",
It looks like the error message that's coming from whatever you're using to try and load the package is incorrect. There's no main
module field in the package.json
file. I suspect that the version of whatever you're using to load the module doesn't understand exports
. You may need to upgrade your tooling.
I saw that other packages also have exports and they all work fine. I don't know where the problem comes from.
error: Error: While trying to resolve module
@digitalbazaar/did-method-key
from fileC:\Users\***\Work\***\app\lib\did.ts
, the packageC:\Users\***\Work\***\\node_modules\@digitalbazaar\did-method-key\package.json
was s uccessfully found. However, this package itself specifies amain
module field that could not be resolved (C:\Users\***\\Work\***\\node_modules\@digitalbazaar\did-method-key\index
. Indeed, none of these files exist: