Skip to content

Commit

Permalink
fix doc
Browse files Browse the repository at this point in the history
  • Loading branch information
gongtao245 committed Mar 9, 2024
1 parent 966acbd commit e5757fa
Show file tree
Hide file tree
Showing 10 changed files with 17 additions and 14 deletions.
2 changes: 1 addition & 1 deletion basic/01-web3js-deploy/README-cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ https://ithelp.ithome.com.tw/articles/10202794 在成功创建 Infura Project
- 同时在 BiliBili 上有上传本样例代码的讲解演示:
https://www.bilibili.com/video/BV1Y44y1r7E6/

--测试Node版本:v20.11.0
- 测试Node版本:v20.11.0

## 合约功能说明
constructor: 构造函数, 用于部署合约时调用, 同时在其中初始化了公共变量 number 的值
Expand Down
2 changes: 1 addition & 1 deletion basic/01-web3js-deploy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Through this basic task, you can learn the processes of compiling and deploying

- If you know Chinese, you can check these tasks on [BILIBILI](https://www.bilibili.com/video/BV1Y44y1r7E6/).

--Node Version:v20.11.0
- Node Version:v20.11.0

# Getting Started

Expand Down
6 changes: 3 additions & 3 deletions basic/02-web3js-transaction/README-cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@
## 前言
通过本样例代码,开发者了解到如何对交易进行签名,发送,接收交易回执,验证交易执行结果。同时,样例也提供了事件监听的逻辑代码,开发者可以了解如何对一个事件进行一次或多次监听

--测试Node版本:v20.11.0

## 合约功能说明
constructor: 构造函数, 用于部署合约时调用, 同时在其中初始化了公共变量 number 的值
increment: 增值函数, 根据传入的数值 ( _value ), 对公共变量 number 进行增值 ( number + _value )
reset: 重置函数, 用于重置公共变量 number 的值为 0
getNumber: 查询函数, 用于查询公共变量 number 当前的数值

## 测试流程
## 测试流程
1) 安装依赖
```
```js
npm install
// 本教程使用的 node 版本为 v20.11.0
```

2) 配置 .env
Expand Down
1 change: 1 addition & 0 deletions basic/02-web3js-transaction/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ You can't use `.sol` files directly, you need to compile it to binary file first
```js
// Load contract
// please use node v20.11.0 to run following commands
const source = fs.readFileSync("Incrementer.sol", "utf8");
```
### Compile the smart contract file
Expand Down
4 changes: 2 additions & 2 deletions basic/03-web3js-erc20/README-cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

本样例演示了 ERC20 合约的基本调用, 让开发者了解 ERC20 合约的基本接口

--测试Node版本:v20.11.0

## SimpleToken 合约功能说明

Expand All @@ -25,8 +24,9 @@

1. 安装依赖

```sh
```js
npm install
// 本教程使用的 node 版本为 v20.11.0
```

2. 配置 .env
Expand Down
1 change: 1 addition & 0 deletions basic/03-web3js-erc20/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ This basic task is to show how to interact with ERC20 contract, so the developer
You can't use `.sol` files directly, you need to compile it to binary file firstly.
1. Load the smart contract file `SimpleToken.sol` into `source` variable.
```js
Expand Down
4 changes: 2 additions & 2 deletions basic/04-web3js-truffle/README-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ truffle 开发框架提供了很多功能,简化了我们的开发、编译、
- 可配的构建流程,支持持续集成。
- 支持外部脚本的执行

--Node Version:v20.11.0

## 文件说明

Expand All @@ -39,8 +38,9 @@ truffle 开发框架提供了很多功能,简化了我们的开发、编译、

## 测试流程
1. 安装 truffle
```bash
```js
npm install -g truffle
// 本教程使用的 node 版本为 v20.11.0
```

如果下载速度过慢,可配置taobao的镜像地址来进行加速。
Expand Down
5 changes: 2 additions & 3 deletions basic/04-web3js-truffle/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
- Configurable build pipeline with support for tight integration.
- External script runner that executes scripts within a Truffle environment.

--Node Version:v20.11.0

### [Truffle Quickstart](https://www.trufflesuite.com/docs/truffle/quickstart)

## Introduction about Project
Expand All @@ -40,8 +38,9 @@

1. Install `Truffle`

```bash
```js
npm install -g truffle
// please use node v20.11.0
```

> Note: If you are live in mainland China, you can change the registry to `taobao`:
Expand Down
3 changes: 2 additions & 1 deletion basic/05-ethersjs-erc20/README-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,9 @@

1. 安装依赖

```sh
```js
npm install
// 本教程使用的 node 版本为 v20.11.0
```

2. 配置 .env
Expand Down
3 changes: 2 additions & 1 deletion basic/05-ethersjs-erc20/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,9 @@ Difference between `web3.js` and `ethers.js` can be seen [here](./web3-vs-ethers

1. Install dependencies

```bash
```js
npm install
// please use node v20.11.0
```

2. Config `.env`
Expand Down

0 comments on commit e5757fa

Please sign in to comment.