0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

node module

Last updated at Posted at 2025-03-15

node module とは

node module (ノードモジュール)とは、実行環境のNode.js 上で動く、「組み込みモジュール」や「ツール」のこと。

  • 組み込みモジュール
    node.js で動かす プログラムに組み込んで使用するモジュール (fs, http, path など)
  • ツール(単体で動くモジュール)
    node.js で動くプログラム (webpack, express など)

モジュールの管理方法

Node.jsのパッケージ管理ツールである npm(Node Package Manager) を使って管理する。
組み込みモジュール fs の追加(インターネット経由で追加される)

npm install fs

具体的なモジュール管理の仕組み

  • node_modules
    ディレクトリの中にモジュールが収められる。
  • package.json
    に追加したモジュールの情報や依存関係が記述される。
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?