Skip to content

A clean, minimal blog starter kit built with Next.js, TypeScript & Tailwind CSS. Perfect for developers who want to quickly set up a personal blog.

License

Notifications You must be signed in to change notification settings

aiferrydermawan/nextjs-blog-starter-kit

Repository files navigation

πŸš€ Next.js Blog Starter Kit

A clean, minimal, and production-ready blog starter kit built with Next.js, TypeScript, and Tailwind CSS. Perfect for developers who want to quickly set up a personal blog or documentation site.

Next.js TypeScript Tailwind CSS License

✨ Features

  • πŸ“ Markdown Support - Write posts in markdown with frontmatter
  • 🎨 Minimal Design - Clean, typography-focused interface
  • πŸ“± Responsive - Mobile-first responsive design
  • ⚑ Fast - Built with Next.js static generation
  • πŸ”’ Type Safe - Full TypeScript support
  • 🎯 SEO Ready - Optimized for search engines
  • πŸš€ Production Ready - Ready to deploy to Vercel, Netlify, etc.
  • πŸ“¦ Zero Config - Get started in minutes

πŸ—οΈ Built With

πŸš€ Quick Start

Prerequisites

  • Node.js 18+
  • npm, yarn, or pnpm

Installation

  1. Clone the repository

    git clone https://github.com/aiferrydermawan/nextjs-blog-starter-kit.git
    cd nextjs-blog-starter-kit
  2. Install dependencies

    npm install
    # or
    yarn install
    # or
    pnpm install
  3. Run development server

    npm run dev
    # or
    yarn dev
    # or
    pnpm dev
  4. Open your browser Navigate to http://localhost:3000

πŸ“ Project Structure

β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ components/          # Reusable UI components
β”‚   β”‚   β”œβ”€β”€ Header.tsx      # Navigation header
β”‚   β”‚   β”œβ”€β”€ Footer.tsx      # Site footer
β”‚   β”‚   └── Layout.tsx      # Page layout wrapper
β”‚   β”œβ”€β”€ lib/                # Utility functions
β”‚   β”‚   └── posts.ts        # Blog post utilities
β”‚   β”œβ”€β”€ pages/              # Next.js pages
β”‚   β”‚   β”œβ”€β”€ index.tsx       # Home page
β”‚   β”‚   β”œβ”€β”€ blog/           # Blog pages
β”‚   β”‚   β”œβ”€β”€ about.tsx       # About page
β”‚   β”‚   └── contact.tsx     # Contact page
β”‚   β”œβ”€β”€ posts/              # Markdown blog posts
β”‚   └── styles/             # Global styles
β”‚       └── globals.css     # Tailwind CSS
β”œβ”€β”€ public/                  # Static assets
β”œβ”€β”€ tailwind.config.js      # Tailwind configuration
β”œβ”€β”€ next.config.ts          # Next.js configuration
└── package.json            # Dependencies and scripts

πŸ“ Adding Blog Posts

1. Create a new markdown file

Create a new .md file in the src/posts/ directory:

touch src/posts/my-new-post.md

2. Add frontmatter

Every post needs frontmatter at the top:

---
title: "My New Blog Post"
slug: "my-new-blog-post"
date: "2024-01-15"
excerpt: "A brief description of your post"
tags: ["nextjs", "react", "web-development"]
---

# Your Post Title

Your content goes here...

3. Write your content

Use standard markdown syntax:

## Section Header

- List item 1
- List item 2

**Bold text** and *italic text*

```javascript
console.log("Code blocks work too!");

4. Your post is live!

The post will automatically appear on your blog page at /blog.

🎨 Customization

Layout & Components

  • Header: Edit src/components/Header.tsx
  • Footer: Edit src/components/Footer.tsx
  • Layout: Edit src/components/Layout.tsx

Styling

  • Global CSS: Edit src/styles/globals.css
  • Tailwind: Modify tailwind.config.js

Blog Configuration

Edit src/lib/posts.ts to add more frontmatter fields or change post processing logic.

πŸ“± Pages

  • Home (/) - Landing page with blog introduction
  • Blog (/blog) - List of all blog posts
  • Post (/blog/[slug]) - Individual blog post pages
  • About (/about) - About page
  • Contact (/contact) - Contact form

πŸš€ Deployment

Vercel (Recommended)

  1. Push your code to GitHub
  2. Import your repository to Vercel
  3. Deploy with zero configuration

Netlify

  1. Push your code to GitHub
  2. Connect your repository to Netlify
  3. Build command: npm run build
  4. Publish directory: .next

Other Platforms

This starter kit works with any platform that supports Next.js:

  • Railway
  • Render
  • DigitalOcean App Platform
  • AWS Amplify

πŸ“Š Performance

  • Lighthouse Score: 95+ across all metrics
  • First Contentful Paint: < 1.5s
  • Largest Contentful Paint: < 2.5s
  • Cumulative Layout Shift: < 0.1

🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Development

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ™ Acknowledgments

πŸ“ž Support

⭐ Star History

Star History Chart


Made with ❀️ by Ferry Dermawan

If this starter kit helps you, please give it a ⭐ star!

About

A clean, minimal blog starter kit built with Next.js, TypeScript & Tailwind CSS. Perfect for developers who want to quickly set up a personal blog.

Topics

Resources

License

Contributing

Security policy

Stars

Watchers

Forks