Export Files as Modules
JSON →export-files is a Node.js utility designed to automatically export all JavaScript files within a specified directory as modules. It provides a simple mechanism to aggregate multiple source files into a single object, where each file's export becomes a property. The current stable version is 3.0.2, with previous major breaking changes noted in v3.0.0 and v0.2.0. A key differentiator is its exclusive focus on CommonJS `require` syntax, explicitly stating it does not support ES Module `import` statements. It offers robust features like recursive directory processing, file filtering, and customizable key casing for the exported modules, making it suitable for organizing larger Node.js projects into modular structures without manual `require` statements for every file.
Traffic · last 30 days ↑400% vs prev 7d
top countries 🇺🇸 United States · 🇫🇷 France · 🇨🇦 Canada · 🇦🇺 Australia · 🇩🇪 Germany