mirror of
https://github.com/lanyeeee/bilibili-video-downloader.git
synced 2026-09-09 01:27:27 +08:00
refactor: 用单独的文件管理commands
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
#[tauri::command]
|
||||||
|
#[specta::specta]
|
||||||
|
pub fn greet(name: &str) -> String {
|
||||||
|
format!("Hello, {}! You've been greeted from Rust!", name)
|
||||||
|
}
|
||||||
@@ -1,11 +1,8 @@
|
|||||||
|
mod commands;
|
||||||
|
|
||||||
use tauri::Wry;
|
use tauri::Wry;
|
||||||
|
|
||||||
// Learn more about Tauri commands at https://tauri.app/develop/calling-rust/
|
use crate::commands::*;
|
||||||
#[tauri::command]
|
|
||||||
#[specta::specta]
|
|
||||||
fn greet(name: &str) -> String {
|
|
||||||
format!("Hello, {}! You've been greeted from Rust!", name)
|
|
||||||
}
|
|
||||||
|
|
||||||
fn generate_context() -> tauri::Context<Wry> {
|
fn generate_context() -> tauri::Context<Wry> {
|
||||||
tauri::generate_context!()
|
tauri::generate_context!()
|
||||||
|
|||||||
Reference in New Issue
Block a user