Something went wrong. Try again.
opencode v2 mirror
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536// The module lists only: `gui()` reads them at build time, so this file imports nothing.
/** * The modules a plugin's `./gui-experimental` bundle may require that both processes provide, each its own instance. * Main maps `@opencode/plugin/gui` to the main SDK and a window maps `@opencode/plugin/gui/main` to the window SDK: * both export the same `Plugin`, `Store`, `Ipc`, `Contract` and `Registry`, so one definition and contract serve both * processes. `@opencode/plugin/rpc` is here because a plugin's `./rpc` contract imports it, and its GUI imports that * contract. */export const pluginSharedModules = [ "effect", "@opencode/plugin/gui", "@opencode/plugin/gui/main", "@opencode/plugin/rpc", "@opencode/schema/rpc", "@opencode/client", "@opencode/client/effect",] as const
/** * The modules only a window provides to a plugin's `./gui-experimental` bundle; main gives the bundle an inert * placeholder. */export const pluginWindowModules = [ "solid-js", "solid-js/web", "solid-js/store", "@opencode/plugin/gui/file", "@opencode/plugin/gui/review", "@opencode/plugin/gui/browser", "@opencode/client/solid",] as const
/** A module name in `pluginSharedModules` or `pluginWindowModules`. */export type PluginModule = (typeof pluginSharedModules)[number] | (typeof pluginWindowModules)[number]