Cargo Features
Wrflib has no features set by default.
[dependencies]
wrflib = { version = "0.0.3", features = ["tls", "cef", "cef-dev-tools", "cef-debug", "cef-server", "cef-bundle"] }
- tls
-
TLS (for HTTPS) doesn't currently work with cross-compilation, so we allow disabling it.
- cef cef-bundle? cef-dev-tools? cef-server? = wrflib_cef
-
Ship a Chromium browser using CEF in the native app.
Affects
cx::CallRustInSameThreadSyncFn
,cx::CxDesktopVsWasmCommon.call_js
,cx::CxDesktopVsWasmCommon.on_call_rust_in_same_thread_sync
,window::Window.create_cef_url
… - cef-dev-tools = cef
-
Show the Chrome DevTools on startup. TODO(JP): should we move this to a keyboard shortcut or so at some point?
- cef-debug
-
Use the CEF debug build, and extra verbose logging.
Enables debug of wrflib_cef
- cef-server cef-bundle? = cef
-
Serve web files from the application bundle
Affects
window::Window.get_resource_url_callback
… - cef-bundle = cef, cef-server
-
Used when building the app bundle
Features from optional dependencies
In crates that don't use the dep:
syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.