feat(serve): multi-tab host and Electron loopback PoC / serve 多 Tab 与 Electron 实验壳 - #7923
Draft
SivanCola wants to merge 1 commit into
Draft
feat(serve): multi-tab host and Electron loopback PoC / serve 多 Tab 与 Electron 实验壳#7923SivanCola wants to merge 1 commit into
SivanCola wants to merge 1 commit into
Conversation
Add tabhost multi-Controller runtime, serve --multi-tab /tabs APIs, and desktopsidebar metadata shared with Wails project-tree files. Ship an experimental Electron shell over loopback reasonix serve with HTTP+SSE host bindings, same-origin shell proxy auth fixes, and multi-project tab UI wiring. Official desktop remains Wails; Electron is additive PoC.
| } | ||
| } | ||
|
|
||
| const upstream = await fetch(target.toString(), init); |
| await serveStatic(req, res, url, staticDir, opts); | ||
| } catch (err) { | ||
| res.writeHead(500, { "Content-Type": "text/plain" }); | ||
| res.end(String(err?.message || err)); |
| } | ||
|
|
||
| func loadTopicTitles(workspaceRoot string) map[string]string { | ||
| b, err := os.ReadFile(topicTitlesPath(workspaceRoot)) |
|
|
||
| func saveTopicTitles(workspaceRoot string, m map[string]string) error { | ||
| path := topicTitlesPath(workspaceRoot) | ||
| if err := os.MkdirAll(filepath.Dir(path), 0o755); err != nil { |
| return err | ||
| } | ||
| tmp := path + ".tmp" | ||
| if err := os.WriteFile(tmp, b, 0o644); err != nil { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
internal/tabhostmulti-Controller runtime andreasonix serve --multi-tab/tabs…HTTP+SSE routes for concurrent project tabs.internal/desktopsidebar+/desktop/*APIs so Electron and Wails sharedesktop-projects.json/ topic metadata for project tree and topic CRUD.electron-poc/shell (loopback serve supervision, same-origin proxy, HttpSseHost, multi-tab desktop UI wiring). Official product remains Wails.Scope / non-goals
Test plan
go test ./internal/tabhost/ ./internal/desktopsidebar/ ./internal/serve/cd electron-poc && npm testnpm run smoke:dual-project(with localREASONIX_BIN)