|
1 | 1 | # WIT Packages |
2 | 2 |
|
3 | | -A **WIT package** is a set of one or more [WIT (Wasm Interface Type)](./wit.md) files |
| 3 | +A **WIT package** is a set of one or more [WebAssembly Interface Type](./wit.md) (WIT) files |
4 | 4 | that, taken together, contain a set of interfaces and worlds that are related to each other. |
5 | | -WIT is an IDL (interface definition language) for the component model. |
| 5 | +WIT is an [interface definition language][wp-idl] (IDL) for the component model. |
6 | 6 | Packages provide a way for worlds and interfaces to refer to each other, |
7 | 7 | and thus for an ecosystem of components to share common definitions. |
8 | 8 |
|
9 | | -A WIT package is like a namespace for grouping related interfaces and worlds together |
| 9 | +A WIT package groups related interfaces and worlds together |
10 | 10 | for ease of discovery and reference. |
11 | | -A package is not a [world](./worlds.md). |
| 11 | +A package is not a [world](./worlds.md): a package maps to one or more files |
| 12 | +and contains worlds. |
| 13 | +A world is a bundle of imported and exported types and interfaces. |
12 | 14 |
|
13 | 15 | * The WebAssembly System Interface (WASI) defines a number of packages, |
14 | 16 | including one named `wasi:clocks`. |
15 | | - Our HTTP proxy world could import the `wall-clock` interface from the `wasi:clocks` package, |
| 17 | + Our HTTP proxy world could import the `wasi:clocks/wall-clock` interface |
| 18 | + (read as "the `wall-clock` interface from the `wasi:clocks` package"), |
16 | 19 | rather than having to define a custom clock interface. |
17 | 20 |
|
18 | 21 | > For a more formal definition of what a WIT package is, take a look at the [WIT specification](https://github.com/WebAssembly/component-model/blob/main/design/mvp/WIT.md). |
| 22 | +
|
| 23 | +[wp-idl]: https://en.wikipedia.org/wiki/Interface_description_language |
0 commit comments