import {info} from "tauri-plugin-log-api";const changeLangAction = async (lang: string) => {info('changeLangAction in render')setStore("lang", lang);setCurrentLang(lang);i18n.changeLanguage(lang);if (IS_TAURI) {invoke("change_menu_language", { lang }).then(() => {relaunch();})...
tauri-plugin-log-api Star Here is 1 public repository matching this topic... CodeEditorLand / TauriPluginLog Star 1 Code Issues Pull requests [READ ONLY] This repository is a mirror, for issue tracking and development head to: https:⁄⁄githubco...
import { trace, info, error, attachConsole } from "tauri-plugin-log-api"; // with LogTarget::Webview enabled this function will print logs to the browser console const detach = await attachConsole(); trace("Trace"); info("Info"); error("Error"); // detach the browser console from ...
Dependencies Upgraded totauri-utils@2.0.0-beta.3 Cargo Publish Updating crates.io index Packaging tauri-plugin v2.0.0-beta.3 (/home/runner/work/tauri/tauri/core/tauri-plugin) Verifying tauri-plugin v2.0.0-beta.3 (/home/runner/work/tauri/tauri/core/tauri-plugin) Updating crates.io index Com...
import { invoke } from "@tauri-apps/api/core"; async function MY_COMMAND() { greetMsg.value = await invoke("greet", { name: name.value }); console.log(await invoke.length); // 有几种可使用的自定义命令 console.log(await invoke('plugin:PLUGIN_NAME|COMMAND_NAME',{my_msg: "可爱幽灵...
首先,我们从tauri-plugin-sql-api中导入Database对象, 关于数据库的操作我们都要依赖这个Database对象 由于tauri-plugin-sql都是支持异步并发操作,所以我们创建的函数都是异步函数, 函数分别是: initDb: 创建数据库连接,这里我们指定SQLite的文件名为example.db,返回创建成功后的数据库db实例 ...
JS/TS API Documentation:https://huakunshen.github.io/tauri-plugin-shellx/ Installation NPM Package:https://www.npmjs.com/package/tauri-plugin-shellx-api Rust Crate:https://crates.io/crates/tauri-plugin-shellx Make sure your npm package version and rust crate version are the same, or you ...
console.log('接收到的推送消息', e.data); }); }); return ()=>{ // 离开界面,需要断开连接 wsInstance && wsInstance.disconnect(); }; }, []); return ( 测试消息推送界面 ); }; 说明:使用tauri-plugin-websocket-api插件,ws和wss协议都支持,此处仅展示了ws协议的使用。
vue3-tauri2chat基于vite5+tauri2.0+vue3 setup+element-plus跨平台仿QQ|微信桌面端聊天应用。全新封装tauri2多窗口管理、自定义透明圆角阴影窗体、打开独立聊天窗口。 技术栈 编码器:VScode 技术框架:tauri2.0+vite5.4.7+vue3.5.8+vue-router^4.4.5 状态管理:pinia^2.2.2 本地存储:pinia-plugin-persistedstate...
Tauri是一个用Rust构建的开源框架,用于创建轻量、安全且高效的跨平台桌面应用,结合Rust与Web技术(HTML/CSS/JS)。它遵循最小权限原则,仅在必要时调用OS API。Tauri架构包括Rust后端、Web前端、Tauri API和包装器。通过`cargo tauri init`可创建新项目,Rust后端处理系统