refactor: 简化开发与生产模式日志输出
- 简化开发与生产模式的日志输出,移除冗余提示信息。
This commit is contained in:
@@ -54,7 +54,7 @@ pub fn spawn_sidecar(app_handle: tauri::AppHandle) {
|
||||
|
||||
if is_dev {
|
||||
// 开发模式:直接创建窗口连接到 Vite 开发服务器
|
||||
println!("🔧 开发模式:连接到 Vite 开发服务器 (localhost:3000)");
|
||||
println!("🔧 开发模式");
|
||||
|
||||
match tauri::WebviewWindowBuilder::new(
|
||||
&app_handle,
|
||||
@@ -69,7 +69,6 @@ pub fn spawn_sidecar(app_handle: tauri::AppHandle) {
|
||||
Ok(_) => println!("✓ 开发窗口创建成功"),
|
||||
Err(e) => {
|
||||
eprintln!("✗ 窗口创建失败: {}", e);
|
||||
eprintln!("提示: 请确保 Vite 开发服务器在 localhost:3000 运行");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -78,7 +77,7 @@ pub fn spawn_sidecar(app_handle: tauri::AppHandle) {
|
||||
|
||||
// 生产模式:启动 sidecar 二进制
|
||||
tauri::async_runtime::spawn(async move {
|
||||
println!("🚀 生产模式:启动 Sidecar App");
|
||||
println!("🚀 生产模式");
|
||||
|
||||
// 查找可用端口
|
||||
let port = find_available_port(DEFAULT_PORT).await;
|
||||
|
||||
Reference in New Issue
Block a user