-
Notifications
You must be signed in to change notification settings - Fork 4
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
Update tx-fees.md #422
Closed
Closed
Update tx-fees.md #422
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -257,6 +257,9 @@ contract SayHello { | |||||
Transaction Fee = (GasPrice * TransactionWeight) / {{ networks.moonbase.tx_weight_to_gas_ratio }} | ||||||
``` | ||||||
|
||||||
!!! 请注意 | ||||||
EIP-1559在Moonbeam上的交易费用根据前个区块的基本费用计算得来。 | ||||||
|
||||||
以下部分更详细地描述了计算交易费用的每个组成部分。 | ||||||
|
||||||
### 基础费用 {: #base-fee} | ||||||
|
@@ -433,6 +436,9 @@ Moonbeam网络实施[`eth_feeHistory`](https://docs.alchemy.com/reference/eth-fe | |||||
|
||||||
以下代码片段使用[Axios HTTP客户端](https://axios-http.com/){target=\_blank}来为最终区块查询[Sidecar端点`/blocks/head`](https://paritytech.github.io/substrate-api-sidecar/dist/#operations-tag-blocks){target=\_blank}。随后,根据交易类型(以太坊API:legacy、EIP-1559或EIP-2930标准以及Substrate API)计算区块中所有交易的交易费用,以及区块中的总交易费用。 | ||||||
|
||||||
!!! 请注意 | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
EIP-1559在Moonbeam上的交易费用根据前个区块的基本费用计算得来。 | ||||||
|
||||||
以下代码示例仅用于演示目的,代码需进行修改并进一步测试后才可正式用于生产环境。 | ||||||
|
||||||
您可以将以下代码片段用于任何基于Moonbeam的网络,但您需要相应地修改`baseFee`。您可以参考[基本费用](#base-fee)部分以获取每个网络的计算结果。 | ||||||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This has to match what is defined in the
moonbeam-mkdocs
repo, so that the css understands and renders the correct colorYou can see where it is defined here: https://github.com/papermoonio/moonbeam-mkdocs/blob/master/material-overrides/assets/stylesheets/moonbeam.css#L627
Same for the other admonitions like remember: https://github.com/papermoonio/moonbeam-mkdocs/blob/master/material-overrides/assets/stylesheets/moonbeam.css#L680
and challenge (not used a whole lot): https://github.com/papermoonio/moonbeam-mkdocs/blob/master/material-overrides/assets/stylesheets/moonbeam.css#L663