You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: nodejs/README.md
-20Lines changed: 0 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -850,26 +850,6 @@ try {
850
850
- Node.js >= 18.0.0
851
851
- GitHub Copilot CLI installed and in PATH (or provide custom `cliPath`)
852
852
853
-
### CJS / CommonJS Support
854
-
855
-
The SDK ships both ESM and CJS builds. Node.js and bundlers (esbuild, webpack, etc.) automatically select the correct format via the `exports` field in `package.json`:
856
-
857
-
-`import` / `from` → ESM (`dist/index.js`)
858
-
-`require()` → CJS (`dist/cjs/index.cjs`)
859
-
860
-
This means the SDK works out of the box in CJS environments such as VS Code extensions bundled with `esbuild format:"cjs"`.
861
-
862
-
### System-installed CLI (winget, brew, apt)
863
-
864
-
If you installed the Copilot CLI separately rather than relying on the SDK's bundled copy, pass `cliPath` explicitly:
865
-
866
-
```typescript
867
-
const client =newCopilotClient({
868
-
cliPath: '/usr/local/bin/copilot', // macOS/Linux
869
-
// cliPath: 'C:\\path\\to\\copilot.exe', // Windows (winget, etc.)
0 commit comments