diff --git a/examples/helloworld/main.rs b/examples/helloworld/main.rs index e51bd0314..46021162a 100644 --- a/examples/helloworld/main.rs +++ b/examples/helloworld/main.rs @@ -10,7 +10,11 @@ fn greet(name: &str) -> String { } fn main() { - tauri::Builder::::new() + #[cfg(not(feature = "cef"))] + let builder = tauri::Builder::::new(); + #[cfg(feature = "cef")] + let builder = tauri::Builder::::new(); + builder .invoke_handler(tauri::generate_handler![greet]) .run(tauri::generate_context!( "../../examples/helloworld/tauri.conf.json" diff --git a/examples/multiwebview/main.rs b/examples/multiwebview/main.rs index ad0bf69a0..2bc221c53 100644 --- a/examples/multiwebview/main.rs +++ b/examples/multiwebview/main.rs @@ -7,7 +7,11 @@ use tauri::{LogicalPosition, LogicalSize, WebviewUrl}; fn main() { - tauri::Builder::default() + #[cfg(not(feature = "cef"))] + let builder = tauri::Builder::::new(); + #[cfg(feature = "cef")] + let builder = tauri::Builder::::new(); + builder .setup(|app| { let width = 800.; let height = 600.;