CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-fs-readdir-recursive

Recursively read a directory and return an array of all file paths

90

1.11x
Overview
Eval results
Files

task.mdevals/scenario-2/

Project File Lister

A utility that recursively lists all files in a project directory and outputs them to the console.

Capabilities

List All Files

  • The utility recursively scans a given directory and returns all file paths within it @test
  • File paths are returned relative to the root directory @test
  • Empty directories return an empty list @test

Display Results

  • Each file path is printed to stdout on a separate line @test

Implementation

@generates

API

/**
 * Lists all files in a directory recursively
 * @param {string} dirPath - The directory path to scan
 * @returns {string[]} Array of relative file paths
 */
function listFiles(dirPath) {
  // IMPLEMENTATION HERE
}

module.exports = { listFiles };

Dependencies { .dependencies }

fs-readdir-recursive { .dependency }

Provides recursive directory reading functionality.

Install with Tessl CLI

npx tessl i tessl/npm-fs-readdir-recursive

tile.json