index.ts 328 B

123456789
  1. import { createClient } from "./gen/client/client.js"
  2. import { type Config } from "./gen/client/types.js"
  3. import { OpencodeClient } from "./gen/sdk.gen.js"
  4. export * from "./gen/types.gen.js"
  5. export function createOpencodeClient(config?: Config) {
  6. const client = createClient(config)
  7. return new OpencodeClient({ client })
  8. }