157af4399f
- 恢复 IPC 类型声明 (src/electron-api.d.ts),修复 31 个 TS2339 错误 - 修复构建断裂:vite.config.ts 改回 electron.vite.config.ts - 修复 2 个 verbatimModuleSyntax type-import 报错 - 修正 .gitignore 构建产物路径 (electron-dist/ -> dist-electron/ + release/) - 清理 55+ 处过时路径注释 - 更新 AGENTS.md 架构文档与 IPC 通道表 - 修正 docs/ROADMAP.md 过时引用
33 lines
950 B
TypeScript
33 lines
950 B
TypeScript
import { createApp } from 'vue'
|
|
import { createPinia } from 'pinia'
|
|
import ElementPlus from 'element-plus'
|
|
import 'element-plus/dist/index.css'
|
|
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
|
|
import { loader } from '@guolao/vue-monaco-editor'
|
|
import * as monaco from 'monaco-editor'
|
|
import editorWorker from 'monaco-editor/esm/vs/editor/editor.worker?worker'
|
|
import jsonWorker from 'monaco-editor/esm/vs/language/json/json.worker?worker'
|
|
import App from './App.vue'
|
|
import './styles/global.css'
|
|
|
|
// Monaco worker setup for Vite
|
|
self.MonacoEnvironment = {
|
|
getWorker(_, label) {
|
|
if (label === 'json') return new jsonWorker()
|
|
return new editorWorker()
|
|
},
|
|
}
|
|
|
|
// Use local monaco-editor
|
|
loader.config({ monaco })
|
|
|
|
const app = createApp(App)
|
|
app.use(createPinia())
|
|
app.use(ElementPlus, { size: 'small' })
|
|
|
|
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
|
|
app.component(key, component)
|
|
}
|
|
|
|
app.mount('#app')
|