You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks @coldcode001 for opening the issue.
Yes, we worked on accepting more types for sha3 in version 4.x
However, it seems to me like a feature-request rather than a bug. The function just works exactly as expected according to the documentation (https://web3js.readthedocs.io/en/v1.2.11/web3-utils.html#sha3)
Is there an existing issue for this?
Current Behavior
Seems it's missing in https://github.com/ChainSafe/web3.js/blob/1.x/packages/web3-utils/types/index.d.ts, could we revise the types definition? otherwise we need to suppress the warnings/erros in typescript.
export function sha3(value: string | BN): string | null;
Expected Behavior
export function sha3(value: string | BN | Buffer): string | null;
export function sha3Raw(value: string | BN | Buffer): string;
Steps to Reproduce
https://github.com/ChainSafe/web3.js/blob/1.x/packages/web3-utils/types/index.d.ts
Web3.js Version
1.7.3
Environment
No response
Anything Else?
Not sure if other methods in v1.x have same issue. But I checked v4.x and it's already fixed.
The text was updated successfully, but these errors were encountered: