feat: initialize Tauri application with Preact framework

- Added main application logic in `src-tauri/src/lib.rs` and `src-tauri/src/main.rs`.
- Configured Tauri settings in `tauri.conf.json`.
- Created basic styling in `src/App.css`.
- Implemented main application component in `src/App.tsx` with greeting functionality.
- Included Preact logo in `src/assets/preact.svg`.
- Set up rendering in `src/main.tsx`.
- Defined TypeScript environment in `vite-env.d.ts` and configured TypeScript settings in `tsconfig.json` and `tsconfig.node.json`.
- Configured Vite for Tauri development in `vite.config.ts`.
This commit is contained in:
Evandro Fonseca Junior committed 2026-01-09 17:25:23 -03:00
1 parent 98fde58d77
commit ce33464c6e
40 files changed
+515 -23

No files matched your search

+14
View File
@@ -0,0 +1,14 @@
// Learn more about Tauri commands at https://tauri.app/develop/calling-rust/
#[tauri::command]
fn greet(name: &str) -> String {
format!("Hello, {}! You've been greeted from Rust!", name)
}
#[cfg_attr(mobile, tauri::mobile_entry_point)]
pub fn run() {
tauri::Builder::default()
.plugin(tauri_plugin_opener::init())
.invoke_handler(tauri::generate_handler![greet])
.run(tauri::generate_context!())
.expect("error while running tauri application");
}
+6
View File
@@ -0,0 +1,6 @@
// Prevents additional console window on Windows in release, DO NOT REMOVE!!
#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]
fn main() {
localaiapp_lib::run()
}