前回までのあらすじ: cargo-componentを使ってWebAssemblyコンポーネント(Wasmコンポーネント)を作りました Wasmtimeで実行しました wasm-toolsを使って作成したコンポーネントのワールドを出力しました 今回の内容: WebAssembly Interface Type(WIT)を使ってWasmコンポーネントのインターフェースを定義します wit-bindgenの力を借りつつ、インターフェースをRustで実装します 実装したWasmコンポーネントをコンポーネントレジストリーに登録します。 用意するもの Rustのツールチェーン cargo-component Wasmtime wasm-tools 前回作成したhello-wasm-cliプロジェクト hello-wasm-cliプロジェクトは次のようなフォルダー構成をしています: . ├── Car
![Hello, world! with Wasm Component(ライブラリー編)](https://cdn-ak-scissors.b.st-hatena.com/image/square/73cb1cb630d041d297eee61ce59b3ab69c9ffc33/height=288;version=1;width=512/https%3A%2F%2Fres.cloudinary.com%2Fzenn%2Fimage%2Fupload%2Fs--aiWcp3Mf--%2Fc_fit%252Cg_north_west%252Cl_text%3Anotosansjp-medium.otf_55%3AHello%25252C%252520world%252521%252520with%252520Wasm%252520Component%2525EF%2525BC%252588%2525E3%252583%2525A9%2525E3%252582%2525A4%2525E3%252583%252596%2525E3%252583%2525A9%2525E3%252583%2525AA%2525E3%252583%2525BC%2525E7%2525B7%2525A8%2525EF%2525BC%252589%252Cw_1010%252Cx_90%252Cy_100%2Fg_south_west%252Cl_text%3Anotosansjp-medium.otf_37%3Achikoski%252Cx_203%252Cy_121%2Fg_south_west%252Ch_90%252Cl_fetch%3AaHR0cHM6Ly9zdG9yYWdlLmdvb2dsZWFwaXMuY29tL3plbm4tdXNlci11cGxvYWQvYXZhdGFyLzgwYzk3YTk1NjEuanBlZw%3D%3D%252Cr_max%252Cw_90%252Cx_87%252Cy_95%2Fv1627283836%2Fdefault%2Fog-base-w1200-v2.png)