Skip to content
This repository was archived by the owner on Mar 5, 2025. It is now read-only.

Conversation

@dvargas92495
Copy link

Description

Change adds a type to Contract.methods. I found myself making this cast manually and couldn't find any issue/context as to why it was previously kept as any.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • I have selected the correct base branch.
  • I have performed a self-review of my own code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have made corresponding changes to the documentation.
  • My changes generate no new warnings.
  • Any dependent changes have been merged and published in downstream modules.
  • I ran npm run dtslint with success and extended the tests and types if necessary.
    • Was running into a failure trying to install dependencies Error: Could not find any Visual Studio installation to use
  • I ran npm run test:unit with success.
    • blocked by above
  • I ran npm run test:cov and my test cases cover all the lines and branches of the added code.
    • blocked by above
  • I ran npm run build and tested dist/web3.min.js in a browser.
    • blocked by above
  • I have tested my code on the live network.
    • blocked by above
  • I have checked the Deploy Preview and it looks correct.
    • blocked by above
  • I have updated the CHANGELOG.md file in the root folder.

@luu-alex luu-alex added 1.x 1.0 related issues Enhancement Includes improvements or optimizations labels Jan 14, 2022
@dvargas92495
Copy link
Author

@luu-alex hey, are there any steps I should take in order to get this reviewed?

@luu-alex
Copy link
Contributor

luu-alex commented Feb 2, 2022

Hey @dvargas92495 sorry we didn't get back to you yet, we'll try getting back to you when we have enough bandwidth for enhancements.

@jdevcs
Copy link
Contributor

jdevcs commented Feb 14, 2022

@dvargas92495 Thanks for your contribution. Currently our team is working on web3.js 4.x for full types support, so if you have time you may review and suggest improvements in 4.x .

@dvargas92495
Copy link
Author

Is web3.js version 4.x the recommended branch to use? when I installed latest from npm, it downloaded a 1.x

From my brief skim, it appears that version 4.x has the appropriate typing for this use case

@spacesailor24
Copy link
Contributor

Is web3.js version 4.x the recommended branch to use? when I installed latest from npm, it downloaded a 1.x

From my brief skim, it appears that version 4.x has the appropriate typing for this use case

@dvargas92495

4.x is still in development, so 1.x is the correct branch/version to use

We have refrained from making changes to 1.x's types because it would be considered a breaking change to anyone who uses TypeScript

We appreciate your PR and will be solving this issue in 4.x

@dvargas92495
Copy link
Author

got it makes sense, feel free to discard this PR then!

@luu-alex luu-alex closed this Feb 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

1.x 1.0 related issues Enhancement Includes improvements or optimizations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants