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?

More than 5 years have passed since last update.

めざせNode.jsライブラリマスター (16)find

Last updated at Posted at 2016-06-18

#【ライブラリ説明】
 ファイル名やフォルダ名の取得

#【プログラム】

var find = require('find');

//現在のディレクトリのファイルを全て取得
find.file(__dirname, function(files) {
  console.log(files);
})

// 現在のディレクトリ下のディレクトリをすべて取得
find.dir(__dirname, function(dirs) {
  console.log(dirs)
})

eachfileやeachdirといった関数もある。

#【参考サイト】
 npm
 github

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?