MCPcopy Index your code
hub / github.com/anomalyco/opencode / pluginSpec

Function pluginSpec

packages/opencode/src/plugin/install.ts:91–96  ·  view source on GitHub ↗
(item: unknown)

Source from the content-addressed store, hash-verified

89}
90
91function pluginSpec(item: unknown) {
92 if (typeof item === "string") return item
93 if (!Array.isArray(item)) return
94 if (typeof item[0] !== "string") return
95 return item[0]
96}
97
98function pluginList(data: unknown) {
99 if (!data || typeof data !== "object" || Array.isArray(data)) return

Callers 1

patchPluginListFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected