# @eggjs/loader-fs

> Loader-facing filesystem abstraction for Egg

Latest version **1.1.0** (published 2026-10-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install @eggjs/loader-fs
pnpm add @eggjs/loader-fs
yarn add @eggjs/loader-fs
bun add @eggjs/loader-fs
```

## Health

**Score 75/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; has provenance; recently updated; high maintenance score; high quality score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 1.1.0 |
| Published | 2026-10-07 |
| First published | 2026-06-22 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM |
| Node | >=22.18.0 |
| Dependencies | 4 |
| Unpacked size | 16.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| Author | fengmk2 |
| Maintainers | gxkl, eggjs-admin, fengmk2, atian25, hyj1991, killagu, coolme200, akitasummer, elrrrrrrr, niania |
| Keywords | egg, fs, loader |

## Links

- npm: https://www.npmjs.com/package/@eggjs/loader-fs
- Repository: https://github.com/eggjs/egg
- Homepage: https://github.com/eggjs/egg/tree/next/packages/loader-fs
- Issues: https://github.com/eggjs/egg/issues
- npm.io page: https://npm.io/package/@eggjs/loader-fs

## Dependencies (4)

- [globby](https://npm.io/package/globby.md) ^11.0.2
- [utility](https://npm.io/package/utility.md) ^2.5.0
- [multimatch](https://npm.io/package/multimatch.md) ^7.0.0
- [@eggjs/utils](https://npm.io/package/@eggjs/utils.md) 5.1.0

## Alternatives

- [unionfs](https://npm.io/package/unionfs.md) — 2.2M weekly downloads
- [path-starts-with](https://npm.io/package/path-starts-with.md) — 35.9K weekly downloads
- [redzip](https://npm.io/package/redzip.md) — 1.2K weekly downloads
- [vscode-anymatch](https://npm.io/package/vscode-anymatch.md) — 848 weekly downloads
- [@ledgerhq/coin-filecoin](https://npm.io/package/@ledgerhq/coin-filecoin.md) — 793 weekly downloads

## Recent versions

- 1.1.0 (latest) — 2026-10-07
- 1.0.0-rc.1 (rc) — 2026-10-06
- 1.0.0-beta.27 (beta) — 2026-09-20
- 1.0.0 — 2026-10-06
- 1.0.0-rc.0 — 2026-09-23
- 1.0.0-beta.26 — 2026-08-07
- 1.0.0-beta.25 — 2026-07-13
- 1.0.0-beta.24 — 2026-07-12
- 1.0.0-beta.23 — 2026-07-11
- 1.0.0-beta.22 — 2026-07-11
- 1.0.0-beta.20 — 2026-07-09
- 1.0.0-beta.19 — 2026-06-29
- 1.0.0-beta.17 — 2026-06-28
- 1.0.0-beta.16 — 2026-06-26
- 1.0.0-beta.15 — 2026-06-26
- … 6 more at https://npm.io/package/@eggjs/loader-fs/versions

## README

# @eggjs/loader-fs

Loader-facing filesystem abstraction for Egg loaders and bundled runtimes.

## Usage

```ts
import { RealLoaderFS, type LoaderFS } from '@eggjs/loader-fs';

const loaderFS: LoaderFS = new RealLoaderFS();
```

`LoaderFS` intentionally covers only the operations required by loader code:
`exists`, `stat`, `realpath`, `readJSON`, `glob`, and `loadFile`. A source with
an authoritative, precomputed directory view may also implement
`getKnownFiles`; `undefined` means discovery should fall back to `glob`, while
an empty array means the directory is authoritatively empty.

---
_Source: https://npm.io/package/@eggjs/loader-fs · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
