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

export type, store slot as string #342

Open
wants to merge 6 commits into
base: staging
Choose a base branch
from

Conversation

21e8
Copy link

@21e8 21e8 commented Jan 14, 2025

hi!

I was told about this and think its a great project, might also use this myself.
browsing the code I found two pretty simple things:

  • we never export the db connection type and use any, whereas we really have it
  • we convert slot to bigint. the table col is numeric, pretty sure it expects a string. .toString() should work for both, numbers and bigints, so we could even upgrade to web3.js 2.0 bigints (if they are even being returned here)

Right now I just wanted to fix the type errors. If you prefer strings over bigints or the other way round, let me know and I can set it straight everywhere.

regards
0xAlice

EDIT: I did some more typescript stuff. we're handling bigint differently, I think to be consistent we either have to use strings everywhere or change the schema have the option {mode: "bigint"} everywhere.

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.

1 participant