WebAssembly / wasm-c-api

Wasm C API prototype
Apache License 2.0
534 stars 77 forks source link

Time to write documentation? #153

Open Hywan opened 3 years ago

Hywan commented 3 years ago

Hello dear all,

For the moment, it is assumed that the project does not provide any documentation. When will it be time to write documentation, and did you already think about the format to use? Will it include examples?

I would be happy to write such documentation. Wasmer now provides a compatible C API to wasm-c-api, but we lose all the documentation and examples that we wrote for the users (see 1 or 2).

Thanks.

peterhuene commented 3 years ago

For what it's worth, Wasmtime tries to document the part of the C API it supports. It's generated from this file which, unfortunately, has to be maintained separately from wasm.h.

The documentation above is Wasmtime-specific since it only covers what is implemented by Wasmtime, so I'm not advocating for using it to document the full C API. Perhaps, instead, we could document wasm.h itself using the same doc comment format so popular tools such as Doxygen can be used to generate the documentation?

Hywan commented 3 years ago

Wasmer already uses Doxygen to document the existing C API. But I didn't want to mix with a side .h file. Hence my question to document wasm.h directly.