Update ruma-api-macros/README.md

This commit is contained in:
Jonas Platte 2019-11-26 00:08:39 +01:00
parent 02a9a6494d
commit 14fa10af6b
No known key found for this signature in database
GPG Key ID: CC154DE0E30B7C67

View File

@ -7,11 +7,13 @@ You define the endpoint's metadata, request fields, and response fields, and the
## Usage ## Usage
Here is an example that shows most of the macro's functionality. This crate is not meant to be used directly; instead, you can use it through the re-exports in ruma-api.
Here is an example that shows most of the macro's functionality:
```rust ```rust
pub mod some_endpoint { pub mod some_endpoint {
use ruma_api_macros::ruma_api; use ruma_api::ruma_api;
ruma_api! { ruma_api! {
metadata { metadata {
@ -55,7 +57,9 @@ pub mod some_endpoint {
## Documentation ## Documentation
ruma-api-macros has [comprehensive documentation](https://docs.rs/ruma-api-macros) available on docs.rs. Please refer to the documentation of the `ruma_api!` re-export in [ruma-api][].
[ruma-api]: https://docs.rs/ruma-api
## License ## License