workflow_websocket/lib.rs
1//!
2//! [<img alt="github" src="https://img.shields.io/badge/github-workflow--rs/workflow--websocket-8da0cb?style=for-the-badge&labelColor=555555&color=8da0cb&logo=github" height="20">](https://github.com/workflow-rs/workflow-websocket)
3//! [<img alt="crates.io" src="https://img.shields.io/crates/v/workflow-websocket.svg?maxAge=2592000&style=for-the-badge&color=fc8d62&logo=rust" height="20">](https://crates.io/crates/workflow-websocket)
4//! [<img alt="docs.rs" src="https://img.shields.io/badge/docs.rs-workflow--websocket-56c2a5?maxAge=2592000&style=for-the-badge&logo=docs.rs" height="20">](https://docs.rs/workflow-websocket)
5//! <img alt="license" src="https://img.shields.io/crates/l/workflow-websocket.svg?maxAge=2592000&color=6ac&style=for-the-badge&logoColor=fff" height="20">
6//!
7//! <img src="https://img.shields.io/badge/client -native-informational?style=for-the-badge&color=50a0f0" height="20">
8//! <img src="https://img.shields.io/badge/client -wasm32/browser -informational?style=for-the-badge&color=50a0f0" height="20">
9//! <img src="https://img.shields.io/badge/client -wasm32/Node Webkit -informational?style=for-the-badge&color=50a0f0" height="20">
10//! <img src="https://img.shields.io/badge/server -native-informational?style=for-the-badge&color=50a0f0" height="20">
11//!
12//! [`workflow-websocket`](self) crate provides async websocket client and
13//! server interfaces. The client interface operates uniformally in native
14//! and in the browser-WASM environment.
15//!
16//! This crate allows you to design APIs that work in regular native rust applications
17//! and function the same in the browser. If used as a foundation for APIs, this crate
18//! makes APIs portable, allowing their use in native/command-line/desktop applications
19//! and web-applications alike.
20//!
21//! - [`client::WebSocket`] operates in browser-WASM or native/tokio-backed environment
22//! - [`server::WebSocketServer`] operates only in native/tokio-backed environment
23//!
24
25pub mod client;
26#[cfg(not(target_arch = "wasm32"))]
27pub mod server;
28
29#[cfg(test)]
30mod test;