bun-nextjs

Solid

This skill should be used when the user asks about "Next.js with Bun", "Bun and Next", "running Next.js on Bun", "Next.js development with Bun", "create-next-app with Bun", or building Next.js applications using Bun as the runtime.

Web & Frontend 162 stars 25 forks Updated 2 weeks ago MIT

Install

View on GitHub

Quality Score: 88/100

Stars 20%
74
Recency 20%
90
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Bun Next.js Run Next.js applications with Bun for faster development and builds. ## Quick Start ```bash # Create new Next.js project with Bun bunx create-next-app@latest my-app cd my-app # Install dependencies bun install # Development bun run dev # Build bun run build # Production bun run start ``` ## Project Setup ### package.json ```json { "scripts": { "dev": "next dev --turbo", "build": "next build", "start": "next start", "lint": "next lint" }, "dependencies": { "next": "^16.1.1", "react": "^19.2.3", "react-dom": "^19.2.3" } } ``` ### Use Bun as Runtime ```json { "scripts": { "dev": "bun --bun next dev", "build": "bun --bun next build", "start": "bun --bun next start" } } ``` The `--bun` flag forces Next.js to use Bun's runtime instead of Node.js. ## Configuration ### next.config.js ```javascript /** @type {import('next').NextConfig} */ const nextConfig = { // Enable experimental features experimental: { // Turbopack (faster dev) turbo: {}, }, // Server-side Bun APIs serverExternalPackages: ["bun:sqlite"], // Webpack config (if needed) webpack: (config, { isServer }) => { if (isServer) { // Allow Bun-specific imports config.externals.push("bun:sqlite", "bun:ffi"); } return config; }, }; module.exports = nextConfig; ``` ## Using Bun APIs in Next.js ### Server Components ```typescript // app/page.tsx (Server Component) import { Database } from "bun:sq...

Details

Author
secondsky
Repository
secondsky/claude-skills
Created
6 months ago
Last Updated
2 weeks ago
Language
TypeScript
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category