Still saying fs.readdir is not a function
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 25/100
- issue の種類
- バグ
- 明瞭さ
- 説明が足りない
- 活発さ
- 停滞
- 技術スタック
- javascript, node.js
- 領域
- tooling
調査の方向性
main.js、./Videos パス、およびレポートに示されている browserify -t brfs コマンドから始めます。Bundle を再現し、require('fs') がどのように扱われるかを調べてから、その動作を brfs の説明および例と比較します。誤用なのか不具合なのかを判断し、具体的で再現可能な修正を文書化できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
I'm fairly new to these modules and NPMs but I've been getting along okay until now, this module seems like it's exactly what I need to fix my TypeError: fs.readdir is not a function. The problem is brfs isn't doing anything and the description/examples are not helping me at all.
How the hell am I supposed to use this module?
The only other thing I can say is that I did install brfs, it is in my dependencies alongside browserify, and the command I use in terminal to output my project is "browserify -t brfs main.js > bundle.js"
Below is my code, I tried some other lines even closer to the examples given but they also did not work, just gave me more errors. What am I missing? Thanks in advance.
const path = require('path');
const fs = require('fs');
// READS ALL FILES IN VIDEO FOLDER //
//joining path of directory
const directoryPath = path.join(__dirname, './Videos');
//passsing directoryPath and callback function
fs.readdir(directoryPath, function (err, files) {
//handling error
if (err) {
return console.log('Unable to scan directory: ' + err);
}
//listing all files using forEach
files.forEach(function (file) {
// Do whatever you want to do with the file
console.log(file);
});
});
- 主要言語
- JavaScript
- スター
- 556
- フォーク
- 58
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
browserify/brfs のほかの issue
-
難易度 3/5 1〜2日 初心者へのやさしさ 30/100
browserify/brfs#100 · コメント 2 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
browserify/brfs#97 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
browserify/brfs#86 · コメント 3 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 42/100
browserify/brfs#80 · コメント 1 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
browserify/brfs#73 ·
browserify/brfs の issue をすべて見る
似ている issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
mongoosejs/mquery#142 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 65/100
メンテナーはふだん 1 日以内に返信
-
Add toro4n to the data modeling tools対応中かも @henriklantzhedstrom-prog が今日担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
neo4j/docs-getting-started#546 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
メンテナーはふだん 25 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
libnativeapi/nativeapi#21 ·