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

Document Formatting #7222

Merged
merged 4 commits into from
Sep 13, 2024
Merged

Document Formatting #7222

merged 4 commits into from
Sep 13, 2024

Conversation

danforbes
Copy link
Contributor

Document formatting - closes #6743

Copy link

github-actions bot commented Aug 26, 2024

Bundle Stats

Hey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle.

As this PR is updated, I'll keep you updated on how the bundle size is impacted.

Total

Files count Total bundle size % Changed
10 639.62 kB 0%
Changeset
File Δ Size
../web3-utils/lib/commonjs/formatter.js 📈 +527 B (+3.67%) 14.01 kB → 14.52 kB
View detailed bundle breakdown

Added

No assets were added

Removed

No assets were removed

Bigger

No assets were bigger

Smaller

No assets were smaller

Unchanged

Asset File Size % Changed
web3.min.js 620.22 kB 0%
../lib/commonjs/index.d.ts 8.69 kB 0%
../lib/commonjs/accounts.d.ts 3.89 kB 0%
../lib/commonjs/types.d.ts 2.67 kB 0%
../lib/commonjs/web3.d.ts 1.38 kB 0%
../lib/commonjs/web3_eip6963.d.ts 1.28 kB 0%
../lib/commonjs/abi.d.ts 999 B 0%
../lib/commonjs/eth.exports.d.ts 280 B 0%
../lib/commonjs/providers.exports.d.ts 183 B 0%
../lib/commonjs/version.d.ts 60 B 0%

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Benchmark

Benchmark suite Current: 608d0b9 Previous: b86d8ca Ratio
processingTx 22506 ops/sec (±7.53%) 22440 ops/sec (±7.06%) 1.00
processingContractDeploy 40209 ops/sec (±7.30%) 38564 ops/sec (±7.90%) 0.96
processingContractMethodSend 16251 ops/sec (±9.26%) 16696 ops/sec (±7.81%) 1.03
processingContractMethodCall 28936 ops/sec (±5.93%) 27650 ops/sec (±7.82%) 0.96
abiEncode 44377 ops/sec (±7.88%) 44651 ops/sec (±6.88%) 1.01
abiDecode 31746 ops/sec (±6.86%) 30424 ops/sec (±7.61%) 0.96
sign 1575 ops/sec (±0.58%) 1574 ops/sec (±0.58%) 1.00
verify 362 ops/sec (±2.57%) 365 ops/sec (±2.65%) 1.01

This comment was automatically generated by workflow using github-action-benchmark.

Copy link
Contributor

@jdevcs jdevcs left a comment

Choose a reason for hiding this comment

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

@danforbes In this doc PR, I'll suggest to create formatting guide using functions in packages like web3.eth.getBlockNumber(..), ...

@danforbes
Copy link
Contributor Author

@danforbes In this doc PR, I'll suggest to create formatting guide using functions in packages like web3.eth.getBlockNumber(..), ...

@jdevcs can you clarify your suggestion? The existing guide uses web3.eth.getBlock as an example. Do you think it would be better to replace that example with one that uses web3.eth.getBlockNumber?

Copy link

codecov bot commented Sep 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.44%. Comparing base (b86d8ca) to head (608d0b9).
Report is 1 commits behind head on 4.x.

Additional details and impacted files
@@           Coverage Diff           @@
##              4.x    #7222   +/-   ##
=======================================
  Coverage   94.44%   94.44%           
=======================================
  Files         216      216           
  Lines        8454     8454           
  Branches     2335     2335           
=======================================
  Hits         7984     7984           
  Misses        470      470           
Flag Coverage Δ
UnitTests 94.44% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@jdevcs
Copy link
Contributor

jdevcs commented Sep 10, 2024

@danforbes In this doc PR, I'll suggest to create formatting guide using functions in packages like web3.eth.getBlockNumber(..), ...

@jdevcs can you clarify your suggestion? The existing guide uses web3.eth.getBlock as an example. Do you think it would be better to replace that example with one that uses web3.eth.getBlockNumber?

what do you think for adding one example for each of sub sections specially for formatting numbers using web3.eth.getBlockNumber

@danforbes
Copy link
Contributor Author

what do you think for adding one example for each of sub sections specially for formatting numbers using web3.eth.getBlockNumber

@jdevcs is this what you had in mind? https://f3916c2c.web3-js-docs.pages.dev/guides/getting_started/return-formats

@jdevcs
Copy link
Contributor

jdevcs commented Sep 13, 2024

what do you think for adding one example for each of sub sections specially for formatting numbers using web3.eth.getBlockNumber

@jdevcs is this what you had in mind? https://f3916c2c.web3-js-docs.pages.dev/guides/getting_started/return-formats

yes, looks very good,

@danforbes danforbes merged commit b3cb1b7 into 4.x Sep 13, 2024
54 checks passed
@danforbes danforbes deleted the feat/docs/formatter branch September 13, 2024 11:32
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.

Formatting Guide
4 participants