Skip to content
This repository has been archived by the owner on Mar 24, 2023. It is now read-only.

Commit

Permalink
docs: fine-tune documentation about Instant Finality (#580)
Browse files Browse the repository at this point in the history
Update addtional-feature.md
  • Loading branch information
Flouse authored Nov 24, 2022
1 parent f22daf4 commit 53beed0
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions docs/addtional-feature.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@

## Instant Finality

Ethereum require a transaction to be on-chain(meaning the transaction is included in the latest block) before returning a final status(aka. transaction receipt) to users so they can know whether the transaction is success or not.
Ethereum requires a transaction to be on-chain (meaning the transaction is included in the latest block) before returning a transaction receipt with final status to users, so they know whether the transaction is success or not.

Godwoken provide a quicker way to confirm transaction. Once the transaction is validated in mempool, users can get instant transaction receipt. This feature is called Instant Finality.
Godwoken provide a faster way to confirm transaction. Once a transaction is verified in the mempool, the instant transaction receipt will be generated immediately. This feature is called `Instant Finality`.

If your want to build a low latency user experience for on-chain interaction in your dapp, you can turn on such feature by using the RPC with additional path or query parameter:
If you want to build a low latency user experience for on-chain interactions in your dApp, you could turn on `Instant Finality` feature by using the RPC **with additional path or query parameter**:

```sh
```bash
# http
https://example_web3_rpc_url?instant-finality-hack=true
https://example_web3_rpc_url/instant-finality-hack
Expand All @@ -17,6 +17,6 @@ https://example_web3_rpc_url/instant-finality-hack
ws://example_web3_rpc_url/ws?instant-finality-hack=true
```

Environment like [Hardhat](https://github.com/NomicFoundation/hardhat) will swallow the http url's query parameter, so you might want to use the `/instant-finality-hack` path to overcome that.
**Note**: Environments like [Hardhat](https://github.com/NomicFoundation/hardhat) will swallow the http url's query parameter, so you might want to use the `/instant-finality-hack` path to overcome that.

Also notice that under such mode, there might have some [compatibility issue](https://github.com/godwokenrises/godwoken-web3/issues/283) with Ethereum toolchain like `ether.js`. If you care more about the compatibility, please use the bare RPC url `https://example_web3_rpc_url`, which is consider to be most compatible with Ethereum.
Also notice that under `instant-finality-hack` mode, there might be some [compatibility issue](https://github.com/godwokenrises/godwoken-web3/issues/283) with Ethereum toolchain like `ether.js`. If you care more about the compatibility, please use the bare RPC url `https://example_web3_rpc_url`, which is considered to be most compatible with Ethereum.

0 comments on commit 53beed0

Please sign in to comment.