diff --git a/documentation/docs/frequently-asked-questions.md b/documentation/docs/frequently-asked-questions.md index 53244186..71cdbd59 100644 --- a/documentation/docs/frequently-asked-questions.md +++ b/documentation/docs/frequently-asked-questions.md @@ -252,6 +252,7 @@ pub async fn respond() { #[tokio::main] async fn main() { tokio::spawn(sample_functions::respond()); + rinf::dart_shutdown().await; } ``` diff --git a/documentation/docs/state-management.md b/documentation/docs/state-management.md index fce75887..9ebb0f66 100644 --- a/documentation/docs/state-management.md +++ b/documentation/docs/state-management.md @@ -12,6 +12,7 @@ Here’s a basic example using the [`messages`](https://crates.io/crates/message ```rust title="native/hub/src/lib.rs" use messages::prelude::*; +use rinf::debug_print; rinf::write_interface!(); @@ -48,12 +49,12 @@ impl Calculator { #[tokio::main] async fn main() { let mut addr = Calculator::start(); - let res = addr.send(Sum(10, 5)).await; - - match res { - Ok(result) => println!("SUM: {}", result), - _ => println!("Communication to the actor has failed"), + let result = addr.send(Sum(10, 5)).await; + match result { + Ok(inner) => debug_print!("SUM: {}", inner), + _ => debug_print!("Communication to the actor has failed"), } + rinf::dart_shutdown().await; } ``` diff --git a/documentation/docs/tutorial.md b/documentation/docs/tutorial.md index b9384706..9e783243 100644 --- a/documentation/docs/tutorial.md +++ b/documentation/docs/tutorial.md @@ -86,6 +86,7 @@ mod tutorial_functions; #[tokio::main] async fn main() { tokio::spawn(tutorial_functions::calculate_precious_data()); + rinf::dart_shutdown().await; } ``` @@ -142,6 +143,7 @@ mod tutorial_functions; #[tokio::main] async fn main() { tokio::spawn(tutorial_functions::stream_amazing_number()); + rinf::dart_shutdown().await; } ``` @@ -231,5 +233,6 @@ mod tutorial_functions; #[tokio::main] async fn main() { tokio::spawn(tutorial_functions::tell_treasure()); + rinf::dart_shutdown().await; } ``` diff --git a/documentation/overrides/home.html b/documentation/overrides/home.html index 29bf45eb..36de97a0 100644 --- a/documentation/overrides/home.html +++ b/documentation/overrides/home.html @@ -1,6 +1,11 @@ {% extends "base.html" %} +{% block htmltitle %} +