summaryrefslogtreecommitdiff
path: root/electron.vite.config.ts
diff options
context:
space:
mode:
authorhaoyuren <13851610112@163.com>2026-03-11 18:16:45 -0500
committerhaoyuren <13851610112@163.com>2026-03-11 18:16:45 -0500
commitebec1a1073f9cc5b69e125d5b284669545ea3d9f (patch)
tree731ae664b9966b6fbd269c55be2ba5c01ee3341f /electron.vite.config.ts
Initial commit: ClaudeTeX - LaTeX editor with Overleaf sync
Features: - Electron + React + TypeScript app with Cosmic Latte theme - CodeMirror 6 editor with LaTeX syntax highlighting - PDF preview with pdf.js, zoom controls, SyncTeX double-click jump - File tree with context menu (new/rename/delete/reveal) - Overleaf Git clone with token auth + macOS Keychain storage - Git pull/push sync for Overleaf projects - Embedded terminal (xterm.js + node-pty) with Claude CLI integration - LaTeX compilation via latexmk with auto package install detection - Structured compile log (errors/warnings) with click-to-navigate - Main document setting (auto-detect or right-click to set) - Custom modal system (input/confirm/alert) - Resizable panel layout (file tree | editor | PDF + terminal) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'electron.vite.config.ts')
-rw-r--r--electron.vite.config.ts25
1 files changed, 25 insertions, 0 deletions
diff --git a/electron.vite.config.ts b/electron.vite.config.ts
new file mode 100644
index 0000000..d5d22d1
--- /dev/null
+++ b/electron.vite.config.ts
@@ -0,0 +1,25 @@
+import { resolve } from 'path'
+import { defineConfig, externalizeDepsPlugin } from 'electron-vite'
+import react from '@vitejs/plugin-react'
+
+export default defineConfig({
+ main: {
+ plugins: [externalizeDepsPlugin()],
+ build: {
+ rollupOptions: {
+ external: ['node-pty']
+ }
+ }
+ },
+ preload: {
+ plugins: [externalizeDepsPlugin()]
+ },
+ renderer: {
+ resolve: {
+ alias: {
+ '@': resolve('src/renderer/src')
+ }
+ },
+ plugins: [react()]
+ }
+})