freya_webview/
lib.rs

1//! WebView support for Freya using WRY.
2//!
3//! This crate provides WebView integration for Freya applications using the WRY library.
4//! WebViews can be embedded in your Freya UI as regular elements.
5//!
6//! # Example
7//!
8//! ```rust,no_run
9//! use freya::prelude::*;
10//! use freya_webview::prelude::*;
11//!
12//! fn main() {
13//!     launch(
14//!         LaunchConfig::new()
15//!             .with_plugin(WebViewPlugin::new())
16//!             .with_window(WindowConfig::new(app)),
17//!     )
18//! }
19//!
20//! fn app() -> impl IntoElement {
21//!     WebView::new("https://example.com").expanded()
22//! }
23//! ```
24
25pub mod component;
26mod element;
27pub mod lifecycle;
28pub mod plugin;
29pub mod registry;
30
31/// Prelude module for convenient imports.
32pub mod prelude {
33    pub use crate::{
34        component::WebView,
35        lifecycle::WebViewManager,
36        plugin::WebViewPlugin,
37        registry::{
38            WebViewConfig,
39            WebViewId,
40        },
41    };
42}