Skip to content

Commit 42c126c

Browse files
fix: links, markdown
1 parent 4bc87ed commit 42c126c

2 files changed

Lines changed: 6 additions & 3 deletions

File tree

component-model/src/language-support/rust.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ cargo add wit-bindgen
112112
> The command above should be run from inside the `adder` directory that was created by
113113
> `cargo new` so as to be sure to add `wit-bindgen` to the dependencies of the right project. Alternatively, you can directly add `wit-bindgen` to the dependencies section of the `Cargo.toml`.
114114
>
115-
> While it is also possible to use `wit-bindgen` as a binary via the [`wit-bindgen-cli`][wit-bindgen-cli]
115+
> While it is also possible to use `wit-bindgen` as a binary via the [`wit-bindgen-cli`][crates-wit-bindgen-cli]
116116
> crate, but here we will focus on a code-first binding build approach.
117117
118118
Once you have `wit-bindgen` as a part of your Rust project (i.e. in `Cargo.toml`), we can use it to generate Rust code bindings for our WIT interface. Update your `src/lib.rs` file to look like the following:
@@ -132,7 +132,7 @@ mod bindings {
132132
}
133133
```
134134

135-
Here we create a module called `bindings` that contains the code output by the [`wit_bindgen::generate` macro][rustdoc-wit-bingen-generate].
135+
Here we create a module called `bindings` that contains the code output by the [`wit_bindgen::generate` macro][rustdoc-wit-bindgen-generate].
136136
Various `struct`s, `interface`s, `enum`s and more might be generated by `wit_bindgen`, so it's often desirable to sequester those new
137137
types to a module that can be referred to later.
138138

component-model/src/tutorial.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ docs = { registry = "docs", metadata = { preferredProtocol = "oci", "oci" = {re
150150
> [!NOTE]
151151
> We have published the [`docs:adder` WIT package](https://github.com/orgs/bytecodealliance/packages/container/package/docs%2Fadder) to GHCR ahead of time, so it is easy to find/access via the configuration above.
152152
>
153-
> To make your own custom WITs available, please use the [`wkg publish`](../../composing-and-distributing/distributing.md#distributing-wit-and-components-by-package-name-with-wkg-publish) command.
153+
> To make your own custom WITs available, please use the [`wkg publish`](./composing-and-distributing/distributing.md#distributing-wit-and-components-by-package-name-with-wkg-publish) command.
154154
155155
With the project scaffolded, now we must actually *implement* a command line application that:
156156

@@ -163,6 +163,7 @@ For reference, see the [completed code listing](https://github.com/bytecodeallia
163163
[wkg]: https://github.com/bytecodealliance/wasm-pkg-tools/tree/main/crates/wkg
164164
[wasm-pkg-tools]: https://github.com/bytecodealliance/wasm-pkg-tools/tree/main
165165
[wiki-entrypoint]: https://en.wikipedia.org/wiki/Entry_point
166+
[cargo]: https://doc.rust-lang.org/cargo
166167

167168
## Composing the calculator
168169

@@ -206,3 +207,5 @@ expanded enum.
206207
Another extension of this tutorial could be to remove the `op` enum and instead modify
207208
`eval-expression` to take in a string that can then be parsed to determine which operator component
208209
to call. Maybe this parser is a component of its own?!
210+
211+
[!NOTE]: #

0 commit comments

Comments
 (0)