1234567891011121314151617 |
- // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
- // SPDX-License-Identifier: Apache-2.0
- // SPDX-License-Identifier: MIT
- #![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]
- #[tauri::command]
- fn greet(window: tauri::Window, name: String) {
- tauri::api::dialog::message(Some(&window), "Tauri Example", api::greet(&name));
- }
- fn main() {
- tauri::Builder::default()
- .invoke_handler(tauri::generate_handler![greet])
- .run(tauri::build_script_context!())
- .expect("error while running tauri application");
- }
|