Files
tongxunruanjian/pc-client/src/processShim.ts
T
KIMI 7ce40e356f 新增 pc-client:畅联 PC 端工程(Electron+React,按确认效果图改造,B-59)
- 基于 openim-electron-demo 改造:工号+密码登录(自研账号服务)、会话列表/聊天窗/通讯录界面重做
- 文字/语音/文件/图片消息、文件拖拽发送、表情面板、一对一语音通话(LiveKit)
- RTC 令牌对接账号服务带鉴权版 /api/rtc_token(Bearer imToken + {room,identity})
- account-service: CORS Allow-Headers 补 authorization(浏览器/渲染进程跨域调 rtc_token 需要)
- 附本地 mock 账号服务(scripts/mock-account-server.js)与截图联调脚本
2026-08-09 09:11:06 +08:00

10 lines
437 B
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
// 部分依赖(如 react-draggable)在模块加载时会读取 process.env,
// 而浏览器环境下 OpenIM SDK 注入的 process 对象可能没有 env,导致白屏。
// 这里在最前面补齐,保证渲染进程(web 预览)也能正常运行。
const w = window as unknown as { process?: { env?: Record<string, string> } };
if (typeof w.process !== "undefined" && !w.process.env) {
w.process.env = {};
}
export {};