@openctx/vscode-lib v0.0.29
OpenCtx library for VS Code extensions
The @openctx/vscode-lib npm package is a library that lets VS Code extensions use OpenCtx functionality. The OpenCtx VS Code extension uses this library.
Usage
Status: experimental, for use by VS Code extension authors only (not end users)
- Add
@openctx/vscode-libas a dependency to your VS Code extension. - In your extension's
activatefunction, callcreateController({...}). - Add the relevant
contributionsto your extension'spackage.json.
See the OpenCtx VS Code extension source code for an example.
Developing this library and your VS Code extension
If you want your VS Code extension to automatically incorporate your latest local changes to this package, you can use pnpm link.
In your VS Code extension's package directory, run the following (where $OPENCTX is the path to the openctx repository root):
cd path/to/your/vscode/extension
pnpm link $OPENCTX/lib/client
pnpm link $OPENCTX/lib/schema
pnpm link $OPENCTX/lib/protocol
pnpm link $OPENCTX/client/vscode-libKnown issues
- Only 1 activated extension can use this library at a time. If a second extension using this library tries to activate, it will encounter name collisions in the commands it registers.
- Providers that are implemented as JavaScript programs must be bundled to CommonJS to be used with VS Code. (ESM-bundled JavaScript providers only work with the VS Code debug extension host.)
Development
- Source code
- Docs
- License: Apache 2.0
12 months ago
10 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
2 years ago