zed/crates/extension_api/wit/since_v0.2.0/nodejs.wit
Marshall Bowers 93a3e8bc94
zed_extension_api: Fork new version of extension API (#17795)
This PR forks a new version of the `zed_extension_api` in preparation
for new changes.

Release Notes:

- N/A

---------

Co-authored-by: Max <max@zed.dev>
2024-09-13 10:54:23 -04:00

13 lines
594 B
Text

interface nodejs {
/// Returns the path to the Node binary used by Zed.
node-binary-path: func() -> result<string, string>;
/// Returns the latest version of the given NPM package.
npm-package-latest-version: func(package-name: string) -> result<string, string>;
/// Returns the installed version of the given NPM package, if it exists.
npm-package-installed-version: func(package-name: string) -> result<option<string>, string>;
/// Installs the specified NPM package.
npm-install-package: func(package-name: string, version: string) -> result<_, string>;
}