Skip to content
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

feat: add ipfsHash helper #713

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

Ansonhkg
Copy link
Collaborator

@Ansonhkg Ansonhkg commented Nov 12, 2024

Description

Add ipfs hash library instead of using previously lit action ipfs due to bundling issue.

Note

  • This need to be tested in the browser

sessionSigs: SessionSigsMap;
debug?: boolean;
}) => {
const res = await this.executeJs({
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why were we using a LA for this? Seems like a tremendous overkill

Comment on lines +689 to +693
return throwError({
message: 'code is required',
errorKind: LIT_ERROR.INVALID_PARAM_TYPE.kind,
errorCode: LIT_ERROR.INVALID_PARAM_TYPE.name,
});
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As this PR is pointing to master (v7) it should be updated to use the new errors

@@ -2,6 +2,7 @@ import { computeAddress } from '@ethersproject/transactions';
import { BigNumber, ethers } from 'ethers';
import { joinSignature, sha256 } from 'ethers/lib/utils';
import { SiweMessage } from 'siwe';
import Hash from 'typestub-ipfs-only-hash';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Docs and IDE say it should be imported this way

Suggested change
import Hash from 'typestub-ipfs-only-hash';
import * as Hash from 'typestub-ipfs-only-hash';

IDE:

No default export found in imported module "typestub-ipfs-only-hash".(import/ default)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants