Developer releases ts-treegen 1.0, a TypeScript library for generating file trees
A developer has released version 1.0.0 of ts-treegen, a lightweight TypeScript library designed to simplify programmatic file and folder generation. The library lets developers describe file structures as plain data using a minimal API of four core functions, replacing scattered fs.writeFileSync calls and manual path logic. ts-treegen is runtime-agnostic, supporting Node.js, Deno, Bun, Cloudflare Workers, and an in-memory mode for testing, with zero external dependencies. It includes built-in path safety that blocks directory traversal and absolute path escapes before any files are written to disk. The library is available via npm and its source code and documentation are hosted on GitHub.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in