Spec-Zone.ru › Deno 2

deno remove

deno remove removes dependencies from your project's configuration file. It is the inverse of deno add.

Basic usage

Remove a package:

›_
deno remove @std/path

Remove multiple packages at once:

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

Where dependencies are removed from

deno remove will look at both deno.json and package.json (if present) and remove the matching dependency from whichever file it is found in.

Removing a dependency does not delete it from the global cache. To reclaim disk space, see deno clean.

Removing a global executable

Pass --global (or -g) to remove a globally installed executable script, the same as deno uninstall --global:

›_
deno remove --global serve

A global removal targets a single executable, so you cannot combine --global with multiple names. Use --root to target a custom installation root.

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

With the --global flag, this is an alias for deno uninstall --global and removes a globally installed executable script:

deno remove --global file_server

Options

--global, -g

Remove globally installed package or module.

--lockfile-only

Install only updating the lockfile.

--minimum-dependency-age<minimum-dependency-age>

(Unstable) The age in minutes, ISO-8601 duration or RFC3339 absolute timestamp (e.g. '120' for two hours, 'P2D' for two days, '2025-09-16' for cutoff date, '2025-09-16T12:00:00+00:00' for cutoff time, '0' to disable).

--package-json

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

--root<root>

Installation root.

Dependency management options

--frozen<BOOLEAN>optional

Error out if lockfile is out of date.

--lock<FILE>optional

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

--no-lock

Disable auto discovery of the lock file.

Last updated on June 25, 2026

© 2018–2025 the Deno authors
Licensed under the MIT License.
https://docs.deno.com/runtime/reference/cli/remove

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API