Skip to content

Commit

Permalink
interactive code moved to the top (#6867)
Browse files Browse the repository at this point in the history
Co-authored-by: Junaid <86780488+jdevcs@users.noreply.github.com>
  • Loading branch information
sarthak1dev and jdevcs authored Mar 12, 2024
1 parent 43e70c1 commit 6d0a0ae
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 12 deletions.
9 changes: 5 additions & 4 deletions docs/docs/guides/getting_started/getting_started.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ sidebar_label: Quickstart

# Quickstart


## Live code editor

<iframe width="100%" height="700px" src="https://stackblitz.com/edit/vitejs-vite-aksddx?embed=1&file=main.js&showSidebar=1"></iframe>

## Installation

If NPM is being used as package manager, use the following for installing the web3.js library.
Expand Down Expand Up @@ -247,7 +252,3 @@ const subscription = uniswapToken.events.Transfer();
subscription.on('data',console.log);
// ↳ [{...},{...}, ...] live events will be printed in the console
```

## Live code editor

<iframe width="100%" height="700px" src="https://stackblitz.com/edit/vitejs-vite-aksddx?embed=1&file=main.js&showSidebar=1"></iframe>
9 changes: 5 additions & 4 deletions docs/docs/guides/wallet/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ sidebar_label: 'Mastering Wallets & Accounts'

# Wallets and Accounts Overview


## Live code editor

<iframe width="100%" height="700px" src="https://stackblitz.com/edit/vitejs-vite-mhuwrk?embed=1&file=main.js&showSidebar=1"></iframe>

## Introduction

A Web3.js `Wallet` is your main entry point if you want to use a private key directly to do any blockchain operations (transactions), also called `Signer` in other libraries.
Expand Down Expand Up @@ -220,7 +225,3 @@ The following is a list of `Accounts` [methods](/libdocs/Wallet) in the `web3.et
- [sign](/libdocs/Accounts#sign)
- [signTransaction](/libdocs/Accounts#signtransaction)


## Live code editor

<iframe width="100%" height="700px" src="https://stackblitz.com/edit/vitejs-vite-mhuwrk?embed=1&file=main.js&showSidebar=1"></iframe>
9 changes: 5 additions & 4 deletions docs/docs/guides/web3_providers_guide/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ sidebar_label: 'Mastering Providers'

# Web3js providers overview


## Live code editor

<iframe width="100%" height="700px" src="https://stackblitz.com/edit/vitejs-vite-zfusfd?embed=1&file=main.js&showSidebar=1"></iframe>

## Introduction

web3.js providers are objects responsible for enabling connectivity with the Ethereum network in various ways. Connecting your web application to an Ethereum node is necessary for sending transactions, querying data, and interacting with smart contracts on the network. In this guide, we will explore the different types of providers available in web3.js, how to set them up, and how to use them in your code.
Expand Down Expand Up @@ -375,7 +380,3 @@ provider.on('error', (error) => {
```



## Live code editor

<iframe width="100%" height="700px" src="https://stackblitz.com/edit/vitejs-vite-zfusfd?embed=1&file=main.js&showSidebar=1"></iframe>

1 comment on commit 6d0a0ae

@github-actions
Copy link

Choose a reason for hiding this comment

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

Benchmark

Benchmark suite Current: 6d0a0ae Previous: 6c075db Ratio
processingTx 9395 ops/sec (±4.69%) 9301 ops/sec (±4.81%) 0.99
processingContractDeploy 39051 ops/sec (±7.32%) 39129 ops/sec (±7.62%) 1.00
processingContractMethodSend 19604 ops/sec (±4.79%) 19443 ops/sec (±5.19%) 0.99
processingContractMethodCall 39171 ops/sec (±5.52%) 38971 ops/sec (±6.34%) 0.99
abiEncode 43808 ops/sec (±7.91%) 44252 ops/sec (±6.92%) 1.01
abiDecode 32413 ops/sec (±6.03%) 30419 ops/sec (±8.89%) 0.94
sign 1706 ops/sec (±0.96%) 1656 ops/sec (±4.08%) 0.97
verify 374 ops/sec (±0.57%) 373 ops/sec (±0.78%) 1.00

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

Please sign in to comment.