Expand description
Access wikipedia articles from Rust.
§Example
use wikipedia_wasm::{Wikipedia, http};
#[tokio::main]
async fn main()
{
let wiki = Wikipedia::<http::default::Client>::default();
let page = wiki.page_from_title("World War II".to_string());
let content = page.get_content().await.unwrap();
assert!(content.starts_with("World War II or the Second World War (1 September 1939 – 2 September 1945)"));
}
Re-exports§
pub use iter::Iter;
Modules§
Structs§
Enums§
- Error
- Wikipedia failed to fetch some information