Doc spelling fixes (#1571)

This commit is contained in:
Justin Starry 2020-09-20 13:50:52 +08:00 committed by GitHub
parent 80b31b9396
commit 0941cba819
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
17 changed files with 22 additions and 23 deletions

View File

@ -2,7 +2,7 @@
## Setting up your local development environment
### Add the WASM target
### Add the Wasm target
```bash
rustup target add wasm32-unknown-unknown

View File

@ -46,7 +46,6 @@ mkdir
natively
onclick
proc
recognise
rlib
roadmap
rollup

View File

@ -20,7 +20,7 @@ If your PR is something bigger create an issue beforehand. This will save everyo
## Spelling and grammar
We recognise that not everyone who contributes to Yew will have "perfect" grammar or be a native
We recognize that not everyone who contributes to Yew will have "perfect" grammar or be a native
English speaker. We're all human; everyone makes mistakes and nobody will look down on you if you
make typos or grammar mistakes (we'll just fix them, merge PRs and move on with life).

View File

@ -133,7 +133,7 @@ implementation of the main page and render the component you are working on on t
### wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc) is a tiny allocator that is much smaller than the allocator that is normally used in Rust binaries. Replacing the default allocator with this one will result in smaller WASM file sizes, at the expense of speed and memory overhead.
[wee\_alloc](https://github.com/rustwasm/wee_alloc) is a tiny allocator that is much smaller than the allocator that is normally used in Rust binaries. Replacing the default allocator with this one will result in smaller Wasm file sizes, at the expense of speed and memory overhead.
The slower speed and memory overhead are minor in comparison to the size gains made by not including the default allocator. This smaller file size means that your page will load faster, and so it is generally recommended that you use this allocator over the default, unless your app is doing some allocation-heavy work.
@ -167,7 +167,7 @@ lto = true
Further more it is possible to optimize size of `wasm` code.
The Rust Wasm Book has a section about reducing the size of WASM binaries:
The Rust Wasm Book has a section about reducing the size of Wasm binaries:
[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
* using `wasm-pack` which by default optimizes `wasm` code in release builds

View File

@ -15,5 +15,5 @@ can be found in the GitHub repository.
## wasm\_bindgen\_test
The Rust Wasm working group maintains a crate called [`wasm_bindgen_test`](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) which allows you to run tests in a browser in similar fashion to how
the built-in `#[test]` procedural macro works. More information is given in the [Rust WASM working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)
the built-in `#[test]` procedural macro works. More information is given in the [Rust Wasm working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)
for this module.

View File

@ -125,7 +125,7 @@ Yewは純粋な関数やコンポーネントをサポートしていません
### wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc)は小さなアロケーターで、Rustのバイナリで使用される通常のものより遥かに小さなものです。
デフォルトのアロケーターと置き換えることで、WASMファイルをより小さくすることができ、速度とメモリのオーバーヘッドを軽減できます。
デフォルトのアロケーターと置き換えることで、Wasmファイルをより小さくすることができ、速度とメモリのオーバーヘッドを軽減できます。
デフォルトのアロケータを含めないことによるサイズの増加と比較して、速度とメモリのオーバーヘッドが悪くなります。
ファイルサイズが小さいことで、ページの読み込みが速くなります。
@ -159,7 +159,7 @@ lto = true
更に`wasm`のコードのサイズを最適化することができます。
The Rust Wasm BookにはWASMバイナリのサイズを小さくすることについてのセクションがあります:
The Rust Wasm BookにはWasmバイナリのサイズを小さくすることについてのセクションがあります:
[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
* `wasm-pack`でデフォルトの`wasm`のコードをリリースビルド時に最適化する

View File

@ -9,4 +9,4 @@ description: Testing your app
## wasm\_bindgen\_test
Rust Wasm ワーキンググループは wasm_bindgen_test というフレームワークをメンテナンスしており、組み込みの #[test] プロシージャルマクロの動作と同様の方法でブラウザでテストを実行することができます。詳細は、[Rust WASM 活動グループのドキュメント](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)に記載されています。
Rust Wasm ワーキンググループは wasm_bindgen_test というフレームワークをメンテナンスしており、組み込みの #[test] プロシージャルマクロの動作と同様の方法でブラウザでテストを実行することができます。詳細は、[Rust Wasm 活動グループのドキュメント](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)に記載されています。

View File

@ -125,7 +125,7 @@ Yewは純粋な関数やコンポーネントをサポートしていません
### wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc)は小さなアロケーターで、Rustのバイナリで使用される通常のものより遥かに小さなものです。
デフォルトのアロケーターと置き換えることで、WASMファイルをより小さくすることができ、速度とメモリのオーバーヘッドを軽減できます。
デフォルトのアロケーターと置き換えることで、Wasmファイルをより小さくすることができ、速度とメモリのオーバーヘッドを軽減できます。
デフォルトのアロケータを含めないことによるサイズの増加と比較して、速度とメモリのオーバーヘッドが悪くなります。
ファイルサイズが小さいことで、ページの読み込みが速くなります。
@ -159,7 +159,7 @@ lto = true
更に`wasm`のコードのサイズを最適化することができます。
The Rust Wasm BookにはWASMバイナリのサイズを小さくすることについてのセクションがあります:
The Rust Wasm BookにはWasmバイナリのサイズを小さくすることについてのセクションがあります:
[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
* `wasm-pack`でデフォルトの`wasm`のコードをリリースビルド時に最適化する

View File

@ -9,4 +9,4 @@ description: Testing your app
## wasm\_bindgen\_test
Rust Wasm ワーキンググループは wasm_bindgen_test というフレームワークをメンテナンスしており、組み込みの #[test] プロシージャルマクロの動作と同様の方法でブラウザでテストを実行することができます。詳細は、[Rust WASM 活動グループのドキュメント](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)に記載されています。
Rust Wasm ワーキンググループは wasm_bindgen_test というフレームワークをメンテナンスしており、組み込みの #[test] プロシージャルマクロの動作と同様の方法でブラウザでテストを実行することができます。詳細は、[Rust Wasm 活動グループのドキュメント](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)に記載されています。

View File

@ -62,7 +62,7 @@ fn change(&mut self, props: Self::Properties) -> ShouldRender {
## wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一个比 Rust 二进制文件中通常使用的分配器还小得多的微型分配器。用这个分配器来替代默认的分配器将使 WASM 文件体积更小,但会牺牲速度和内存开销。
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一个比 Rust 二进制文件中通常使用的分配器还小得多的微型分配器。用这个分配器来替代默认的分配器将使 Wasm 文件体积更小,但会牺牲速度和内存开销。
对比不包含默认分配器换取的体积大小,牺牲的速度和内存开销是微不足道的。较小的文件体积意味着你的页面将加载更快,因此通常建议使用此分配器而不是默认分配器,除非你的应用程序会执行一些繁重的内存分配任务。

View File

@ -62,7 +62,7 @@ fn change(&mut self, props: Self::Properties) -> ShouldRender {
## wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一个比 Rust 二进制文件中通常使用的分配器还小得多的微型分配器。用这个分配器来替代默认的分配器将使 WASM 文件体积更小,但会牺牲速度和内存开销。
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一个比 Rust 二进制文件中通常使用的分配器还小得多的微型分配器。用这个分配器来替代默认的分配器将使 Wasm 文件体积更小,但会牺牲速度和内存开销。
对比不包含默认分配器换取的体积大小,牺牲的速度和内存开销是微不足道的。较小的文件体积意味着你的页面将加载更快,因此通常建议使用此分配器而不是默认分配器,除非你的应用程序会执行一些繁重的内存分配任务。

View File

@ -75,7 +75,7 @@ Yew 最大的缺點就是花太多時間在編譯上了。編譯時間似乎和
### wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一個比一般用在 Rust 二進制檔中的分配器更輕量的分配器。用他取代預設的分配器,可以讓 WASM 的檔案大小更小,但是會造成速度和記憶體的開銷變大。
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一個比一般用在 Rust 二進制檔中的分配器更輕量的分配器。用他取代預設的分配器,可以讓 Wasm 的檔案大小更小,但是會造成速度和記憶體的開銷變大。
但比起檔案大小,速度和記憶體的開銷比較次要。更小的檔案大小意味著你的頁面可以載入的更快,因此我們通常建議你使用這個分配器作為預設的分配器,除分你的專案有很多吃重的記憶體分配工作。
@ -111,7 +111,7 @@ lto = true
wasm-opt 資訊: [binaryen project](https://github.com/WebAssembly/binaryen)
Rust Wasm 中有一個關於減少 WASM 二進位檔大小的章節:[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
Rust Wasm 中有一個關於減少 Wasm 二進位檔大小的章節:[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
* 使用`wasm-pack` 預設在發行版本編譯時優化 `wasm` 程式碼
* 直接在 wasm 檔案上使用 `wasm-opt`

View File

@ -8,5 +8,5 @@ description: 測試你的專案
## wasm\_bindgen\_test <a id="wasm_bindgen_test"></a>
Rust WASM 工作群組有維護一個 crate 叫作 [`wasm_bindgen_test`](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) ,他讓你可以在瀏覽器裡跑類似於用內建的巨集`#[test]`測試流程。 更多資訊可以參考 [Rust WASM working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)
Rust Wasm 工作群組有維護一個 crate 叫作 [`wasm_bindgen_test`](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) ,他讓你可以在瀏覽器裡跑類似於用內建的巨集`#[test]`測試流程。 更多資訊可以參考 [Rust Wasm working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html)。

View File

@ -75,7 +75,7 @@ Yew 最大的缺點就是花太多時間在編譯上了。編譯時間似乎和
### wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一個比一般用在 Rust 二進制檔中的分配器更輕量的分配器。用他取代預設的分配器,可以讓 WASM 的檔案大小更小,但是會造成速度和記憶體的開銷變大。
[wee\_alloc](https://github.com/rustwasm/wee_alloc) 是一個比一般用在 Rust 二進制檔中的分配器更輕量的分配器。用他取代預設的分配器,可以讓 Wasm 的檔案大小更小,但是會造成速度和記憶體的開銷變大。
但比起檔案大小,速度和記憶體的開銷比較次要。更小的檔案大小意味著你的頁面可以載入的更快,因此我們通常建議你使用這個分配器作為預設的分配器,除分你的專案有很多吃重的記憶體分配工作。
@ -111,7 +111,7 @@ lto = true
wasm-opt 資訊: [binaryen project](https://github.com/WebAssembly/binaryen)
Rust Wasm 中有一個關於減少 WASM 二進位檔大小的章節:[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
Rust Wasm 中有一個關於減少 Wasm 二進位檔大小的章節:[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
* 使用`wasm-pack` 預設在發行版本編譯時優化 `wasm` 程式碼
* 直接在 wasm 檔案上使用 `wasm-opt`

View File

@ -8,5 +8,5 @@ description: 測試你的專案
## wasm\_bindgen\_test <a id="wasm_bindgen_test"></a>
Rust WASM 工作群組有維護一個 crate 叫作 [`wasm_bindgen_test`](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) ,他讓你可以在瀏覽器裡跑類似於用內建的巨集`#[test]`測試流程。 更多資訊可以參考 [Rust WASM working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) 。
Rust Wasm 工作群組有維護一個 crate 叫作 [`wasm_bindgen_test`](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) ,他讓你可以在瀏覽器裡跑類似於用內建的巨集`#[test]`測試流程。 更多資訊可以參考 [Rust Wasm working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) 。

View File

@ -128,7 +128,7 @@ implementation of the main page and render the component you are working on on t
### wee\_alloc
[wee\_alloc](https://github.com/rustwasm/wee_alloc) is a tiny allocator that is much smaller than the allocator that is normally used in Rust binaries. Replacing the default allocator with this one will result in smaller WASM file sizes, at the expense of speed and memory overhead.
[wee\_alloc](https://github.com/rustwasm/wee_alloc) is a tiny allocator that is much smaller than the allocator that is normally used in Rust binaries. Replacing the default allocator with this one will result in smaller Wasm file sizes, at the expense of speed and memory overhead.
The slower speed and memory overhead are minor in comparison to the size gains made by not including the default allocator. This smaller file size means that your page will load faster, and so it is generally recommended that you use this allocator over the default, unless your app is doing some allocation-heavy work.
@ -162,7 +162,7 @@ lto = true
Further more it is possible to optimize size of `wasm` code.
The Rust Wasm Book has a section about reducing the size of WASM binaries:
The Rust Wasm Book has a section about reducing the size of Wasm binaries:
[Shrinking .wasm size](https://rustwasm.github.io/book/game-of-life/code-size.html)
* using `wasm-pack` which by default optimizes `wasm` code in release builds

View File

@ -9,5 +9,5 @@ original_id: testing
## wasm\_bindgen\_test
The Rust Wasm working group maintains a crate called [`wasm_bindgen_test`](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) which allows you to run tests in a browser in similar fashion to how the built-in `#[test]` procedural macro works. More information is given in the [Rust WASM working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) for this module.
The Rust Wasm working group maintains a crate called [`wasm_bindgen_test`](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) which allows you to run tests in a browser in similar fashion to how the built-in `#[test]` procedural macro works. More information is given in the [Rust Wasm working group's documentation](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/index.html) for this module.