Skip to content

Latest commit

 

History

History
21 lines (17 loc) · 898 Bytes

File metadata and controls

21 lines (17 loc) · 898 Bytes

AGENTS.md

Build Commands

  • pnpm install - Install dependencies
  • pnpm run build - Build extension (output: OpenCode.novaextension/Scripts/)
  • pnpm run build:watch - Build with file watching
  • pnpm run build:install - Build extension and install

Code Style

  • TypeScript strict mode with noUncheckedIndexedAccess
  • Tabs for indentation, no semicolons, double quotes
  • Use import type for type-only imports
  • Prefer named functions over arrow functions
  • Private class fields use # prefix (e.g., #client)
  • Services: singleton pattern (export const fooService = new FooService())
  • Naming: PascalCase for classes/types, camelCase for functions/variables
  • Console logs prefixed with [OpenCode]
  • Error handling: try/catch, show user notifications via NotificationRequest
  • Prefer discriminated unions for variant types (e.g., { type: "FILE" } | { type: "FOLDER" })