A modern blog built with Next.js 15, React 19, TypeScript, and CSS Modules. Features include dark mode, markdown support with syntax highlighting, search functionality, and Vercel Analytics.
- 🌓 Dark/Light mode
- 📝 Markdown support
- 🎨 Syntax highlighting for code blocks
- 🔍 Search functionality
- 📱 Responsive design
- 🎯 SEO friendly
- 🚀 Fast page loads
- 💅 CSS Modules for styling
- 📊 Vercel Analytics & Speed Insights
- 💬 Giscus comments integration
- 📦 Exact dependency versions for reproducible builds
- Next.js: 15.5.12 (App Router)
- React: 19.2.4
- TypeScript: 5.9.3
- Markdown: markdown-to-jsx 9.7.3
- Syntax Highlighting: Prism.js 1.30.0
- Theming: next-themes 0.4.6
- Analytics: Vercel Analytics & Speed Insights
- Comments: Giscus
- Node.js: 24.0.0+
- Node.js 24.0.0 or later
- npm
- asdf (optional, for managing Node.js versions)
- Clone the repository:
git clone https://github.com/helderberto/helderberto.com.git
cd helderberto.com- Install Node.js 24 (using asdf):
asdf install nodejs 24.0.0Or use the .tool-versions file:
asdf install- Install dependencies:
npm installNote: This project uses exact dependency versions (.npmrc with save-exact=true) for reproducible builds.
- Add your profile picture:
- Place your profile picture in
public/profile.jpg
- Update content:
- Edit
content/about.mdwith your information - Add blog posts in the
postsdirectory
Run the development server:
npm run devOpen http://localhost:3000 in your browser.
Available commands:
npm run dev- Start development servernpm run build- Create production buildnpm run start- Start production servernpm run lint- Run ESLint
Create a production build:
npm run buildThis will:
- Compile TypeScript
- Run linting
- Generate static pages
- Optimize bundles
- Export static site
Start the production server:
npm start├── .npmrc # npm config (exact versions)
├── .tool-versions # asdf version management (Node 24)
├── content/
│ └── about.md # About page content
├── posts/ # Blog posts in markdown
├── public/ # Static files
│ └── profile.jpg # Your profile picture
└── src/
├── app/
│ ├── about/ # About page
│ ├── posts/[slug]/ # Dynamic blog post pages
│ └── layout.tsx # Root layout with theme provider
├── components/
│ ├── CodeBlock.tsx # Syntax highlighting
│ ├── Comments.tsx # Giscus comments
│ ├── MarkdownContent.tsx # Client-side markdown renderer
│ ├── ThemeProvider.tsx # Theme management
│ └── ...
├── config/ # Site configuration
├── lib/ # Utility functions
└── types/ # TypeScript type definitions
Create a new markdown file in the posts directory:
---
title: "Your Post Title"
date: "YYYY-MM-DD"
excerpt: "A brief description of your post"
---
# Your Post Title
Your content here...Your code blocks here...
Edit the color variables in src/app/globals.css:
:root {
--background: #ffffff;
--foreground: #000000;
--primary: #3b82f6;
/* ... other colors */
}The project uses the Inter font by default. To change it, edit src/app/layout.tsx.
This project is optimized for deployment on Vercel:
- Push your code to GitHub
- Import your repository in Vercel
- Vercel will automatically detect Next.js and configure the build settings
- Your site will be deployed with automatic CI/CD
The project uses:
- Static Site Generation (SSG) for blog posts
- Automatic static optimization
- ISR (Incremental Static Regeneration) support
This project uses the latest versions of React and Next.js with proper server/client component boundaries:
- Server Components for optimal performance
- Client Components only where needed (theme, syntax highlighting, comments)
- Streaming and Suspense support
- All dependencies use exact versions for reproducible builds
- Regular security updates via Dependabot
- Zero known vulnerabilities (checked with
npm audit)
- Optimized bundle sizes with code splitting
- Lazy loading of components
- Efficient image optimization
- Fast page loads with static generation
If you encounter hydration errors with code blocks:
- Clear the
.nextdirectory:rm -rf .next - Restart the dev server:
npm run dev
Ensure you're using Node.js 24.0.0 or later:
node --version # Should output v24.x.xIf using asdf:
asdf current nodejsIf the build fails:
- Delete
node_modulesandpackage-lock.json - Run
npm installagain - Clear Next.js cache:
rm -rf .next
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Make your changes following the project conventions:
- Use TypeScript
- Follow existing code style
- Update tests if applicable
- Commit your changes with clear, concise messages
- Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request with a clear description
This project is licensed under the MIT License - see the LICENSE file for details.