Skip to main content
On this page

deno remove

deno remove 会从你的项目配置文件中移除依赖。它与 deno add 相反。

基本用法 Jump to heading

移除一个包:

>_
deno remove @std/path

一次移除多个包:

>_
deno remove @std/path @std/assert npm:express

从哪里移除依赖 Jump to heading

deno remove 会查看 deno.jsonpackage.json(如果 存在),并从它所在的文件中移除匹配的依赖项。

移除依赖不会将其从全局缓存中删除。要回收磁盘 空间,请参见 deno clean

Command line usage:
deno remove [OPTIONS] [packages]...

Remove dependencies from the configuration file.

deno remove @std/path

You can remove multiple dependencies at once:

deno remove @std/path @std/assert

Dependency management options Jump to heading

--frozen<BOOLEAN>optional
Jump to heading

Error out if lockfile is out of date.

--lock<FILE>optional
Jump to heading

Check the specified lock file. (If value is not provided, defaults to "./deno.lock").

Disable auto discovery of the lock file.

Options Jump to heading

--lockfile-only
Jump to heading

Install only updating the lockfile.

--package-json
Jump to heading

Force using package.json for dependency management instead of deno.json.

Last updated on

Did you find what you needed?

编辑此页面
Privacy policy