diff --git a/docs/FlecsRemoteApi.md b/docs/FlecsRemoteApi.md index df8136a41..48993ac1c 100644 --- a/docs/FlecsRemoteApi.md +++ b/docs/FlecsRemoteApi.md @@ -46,6 +46,19 @@ world.set({}); while (world.progress()) { } ``` + +
  • Rust + +```rust +// Optional, gather statistics for explorer +world.import::(); + +// Creates REST server on default port (27750) +world.set(flecs::rest::Rest::default()); + +// Runs the system serving up REST requests +while world.progress() {} +```
  • @@ -77,6 +90,17 @@ world.app() .run(); ``` + +
  • Rust + +```rust +world + .app() + // Optional, gather statistics for explorer + .enable_stats(true) + .enable_rest(0) + .run(); +```
  • @@ -268,6 +292,19 @@ world.set({}); while (world.progress()) { } ``` + +
  • Rust + +```rust +// Optional, gather statistics for explorer +world.import::(); + +// Creates REST server on default port (27750) +world.set(flecs::rest::Rest::default()); + +// Runs the system serving up REST requests +while world.progress() {} +```