Run npm run test:custom-document-loader, or npm run test to test the custom document loader.
Integrating with open-attestation-cli
In open-attestation-cli/package.json, specify the version of open-attestation as "@govtechsg/open-attestation": "github:eugbyte/open-attestation#fix/document-loader",
Add the following script command: "build:binary": "npm run build && pkg ./package.json --out-path dist/@govtechsg",
Run npm i.
Run npm build:binary
Result
Still does not work, Error message and the stack trace is oddly still the same. This is despite the fact that the verify file in open-attestation no longer uses the loader component of jsonLd.
Testing
Run
npm run test:custom-document-loader
, ornpm run test
to test the custom document loader.Integrating with open-attestation-cli
In
open-attestation-cli/package.json
, specify the version of open-attestation as"@govtechsg/open-attestation": "github:eugbyte/open-attestation#fix/document-loader",
Add the following script command:"build:binary": "npm run build && pkg ./package.json --out-path dist/@govtechsg",
Runnpm i
. Runnpm build:binary
Result
Still does not work, Error message and the stack trace is oddly still the same. This is despite the fact that the verify file in open-attestation no longer uses the loader component of jsonLd.
My hypothesis is that there are other component that uses the unforked version of open-attestation, where this change has not been implemented.
If you peer into package.lock.json, you will notice
govtechsg/oa-verify
depending on the unabridged version of open-attestation