daumdic-rs 
Daum Dictionary API wrapper written in Rust, inspired by daumdic-ruby.
use search;
async
Ruby compatibility
Search implements Ruby-style one-line formatting, not exact compatibility with
Daumdic.one_liner. Use search(...).await?.to_string() for this output;
formatting an individual Word always includes its word.
- Hanja readings are included, even where the Ruby library omits them.
- No search results produce an empty
Searchand an empty display string, rather than Ruby'snil. - Empty or whitespace-only input returns
Err(DaumdicError::EmptyWord), rather thannil. Rust's Unicode whitespace trimming also differs from Ruby'sstrip. - HTTP error status codes are not checked before parsing the response; Ruby's
open-uriraises for these errors.
The parsers also differ for missing elements and repeated headword elements, so identical output is not guaranteed for every response.
Testing
cargo test runs deterministic tests against saved HTML fixtures and compiles
network examples without executing them. No dictionary access is needed.
Run the live integration test separately (requires network access):
Live results depend on Daum's availability, rate limits, and current content.
daumdic-rs is primarily distributed under the terms of both the Apache License (Version 2.0) and the MIT license. See COPYRIGHT for details.