TidGi-Desktop/docs/internal/ServiceIPC.md
2023-07-09 00:52:11 +08:00

890 B

Service IPC

Register a new service

See this 6aedff4b commit for example, you need to modify these files:

Sync service

Some services are sync, like getSubWorkspacesAsListSync getActiveWorkspaceSync from src/services/workspaces/index.ts, they can't be called from renderer, only can be used in the main process.

Because after pass through IPC, everything will be async, so its function typescript signature will be wrong.