Bun File System Router
Bun provides a fast API for resolving routes against file-system paths
Install
npx skills add jarle/bun-skills --skill Bun File System Routergit clone --depth 1 https://github.com/jarle/bun-skills.git /tmp/bun-skills
mkdir -p ~/.claude/skills
cp -r /tmp/bun-skills/skills/bun-runtime-file-system-router ~/.claude/skills/Bun-File-System-RouterPersonal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.
From the SKILL.md
# File System Router
> Bun provides a fast API for resolving routes against file-system paths
This API is primarily intended for library authors. At the moment only Next.js-style file-system routing is supported, but other styles may be added in the future.
## Next.js-style
The `FileSystemRouter` class can resolve routes against a `pages` directory. (The Next.js 13 `app` directory is not yet supported.) Consider the following `pages` directory:
```txt theme={"theme":{"light":"github-light","dark":"dracula"}}
pages
├── index.tsx
├── settings.tsx
├── blog
│ ├── [slug].tsx
│ └── index.tsx
└── [[...catchall]].tsx
```
The `FileSystemRouter` can be used to resolve routes against this directory:
```ts router.ts theme={"theme":{"light":"github-light","dark":"dracula"}}
const router = new Bun.FileSystemRouter({
style: "nextjs",
dir: "./pages",
origin: "https://mydomain.com",
assetPrefix: "_next/static/"
});
router.match("/");
// =>
{
filePath: "/path/to/pages/index.tsx",
kind: "exact",
name: "/",
pathname: "/",
src: "https://mydomain.com/_next/static/pages/index.tsx"
}
```
Query parameters will be parsed and returned in the `query` property.Details
- Skill name
Bun File System Router- Repository
- jarle/bun-skills
- Path
skills/bun-runtime-file-system-router/SKILL.md- License
- MIT
- Repo updated
- 24 February 2026
FAQ
What does the Bun File System Router skill do?
Bun provides a fast API for resolving routes against file-system paths
How do I install the Bun File System Router skill?
skills CLI (Claude Code, Cursor, Codex and more): npx skills add jarle/bun-skills --skill Bun File System Router. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.
Is Bun File System Router popular?
It lives in jarle/bun-skills, which has 9 GitHub stars and 1 forks.
Related skills
Bun Archive
9jarle/bun-skills
Create and extract tar archives with Bun's fast native implementation
Bun Auto Install
9jarle/bun-skills
Bun's automatic package installation feature for standalone script execution
Bun Bun Add
9jarle/bun-skills
Add packages to your project with Bun's fast package manager
Bun Hot Reloading
9jarle/bun-skills
Hot Module Replacement (HMR) for Bun's development server
Bun FFI
9jarle/bun-skills
Use Bun's FFI module to efficiently call native libraries from JavaScript
Bun Macros
9jarle/bun-skills
Run JavaScript functions at bundle-time with Bun macros
Browse the most popular Claude skills, all software development skills, or write your own with the skills generator.