A personal blog website dedicated to Programmable Logic Controller (PLC) topics and industrial automation.
π Live Demo: https://jakemaney88.dpdns.org
π Deployment Guide: See DEPLOY_STEPS.md
- β Markdown-based blog posts - Easy content management with front matter support
- β Categories & Tags - Organize content by topic and tags
- β Dark Mode - Toggle between light and dark themes
- β Responsive Design - Works perfectly on desktop, tablet, and mobile
- β Fast Performance - Built with Next.js 14 for optimal speed
- β SEO Optimized - Meta tags and structured data for better search results
- β Static Generation - Fast page loads with pre-rendered content
- Framework: Next.js 14 - React-based framework with App Router
- Styling: Tailwind CSS - Utility-first CSS framework
- Content: Markdown files with front matter (YAML)
- Theme: next-themes - Dark mode support
- Markdown Processing: gray-matter & remark
- Date Formatting: date-fns
/PLC-blog
βββ public/ # Static assets
βββ src/
β βββ app/ # Next.js App Router
β β βββ layout.tsx # Root layout
β β βββ page.tsx # Home page
β β βββ blog/ # Blog pages
β β βββ categories/ # Category pages
β β βββ tags/ # Tag pages
β βββ components/ # React components
β β βββ Header.tsx
β β βββ Footer.tsx
β β βββ ThemeToggle.tsx
β β βββ ThemeProvider.tsx
β βββ lib/ # Utility functions
β β βββ posts.ts # Blog post utilities
β β βββ utils.ts # Helper functions
β βββ styles/ # Global styles
β β βββ globals.css
β βββ content/
β βββ posts/ # Markdown blog posts
βββ .eslintrc.json
βββ next.config.js
βββ package.json
βββ postcss.config.js
βββ tailwind.config.ts
βββ tsconfig.json
βββ README.md
- Node.js 18+ and npm
-
Clone the repository (or extract the files):
cd /home/jake/PLC-blog -
Install dependencies:
npm install
-
Run the development server:
npm run dev
-
Open http://localhost:3000 in your browser
Create new Markdown files in src/content/posts/ with the following format:
---
title: Post Title
date: 2024-01-15
category: Category Name
tags: [tag1, tag2, tag3]
excerpt: Brief summary of the post
---
# Post Title
Your content here...Front Matter Fields:
title(required): Post titledate(required): Publication date (YYYY-MM-DD format)category(required): Post category for organizationtags(required): Array of tags for classificationexcerpt(required): Brief summary for previews
# Development server
npm run dev
# Production build
npm build
# Start production server
npm start
# Run ESLint
npm run lint- Automatic detection of system preferences
- Manual toggle button in the header
- Persistent storage in localStorage
- Smooth transitions between themes
- Home Page: Displays latest 5 posts with excerpt
- Blog Page: List all posts with filtering
- Category Pages: Browse posts by category
- Tag Pages: Browse posts by tags
- Post Navigation: Previous/Next links on post pages
- Static generation of all blog pages
- Incremental Static Regeneration (ISR) for new posts
- Optimized images and assets
- Minimal CSS bundle
-
Create GitHub Repository:
git remote add origin https://github.com/jakemaney2025-crypto/plc-blog.git git branch -M main git push -u origin main
-
Deploy to Vercel:
- Visit https://vercel.com
- Connect your GitHub account
- Import the
plc-blogrepository - Deploy with one click
-
Bind Custom Domain:
- In Vercel project settings, go to "Domains"
- Add your domain:
jakemaney88.dpdns.org - Update DNS records at your domain provider
- Wait for DNS propagation (15 min - 48 hours)
For detailed instructions, see DEPLOY_STEPS.md
After initial setup, simply push to GitHub:
./push.sh "Your commit message"
# or
git add .
git commit -m "Your commit message"
git push origin mainVercel will automatically deploy your changes within 2-3 minutes!
Edit src/app/layout.tsx to update site title and description.
Modify the color scheme in tailwind.config.ts:
colors: {
primary: '#0066cc',
secondary: '#333333',
},- Comments: Integrate Giscus
- Search: Add full-text search functionality
- Analytics: Integrate with Google Analytics or Vercel Analytics
- Social Sharing: Add social media sharing buttons
- Push your code to GitHub
- Go to vercel.com
- Import the repository
- Deploy with one click
- Netlify: Supports Next.js with zero configuration
- Self-hosted: Use
npm run buildand deploy to your server
- Post Naming: Use kebab-case for file names (e.g.,
my-post-title.md) - Dates: Keep dates in YYYY-MM-DD format for consistency
- Categories: Keep category names consistent across posts
- Images: Place images in
public/images/and reference with/images/ - SEO: Write descriptive excerpts (150-160 characters)
- Check that markdown files are in
src/content/posts/ - Ensure front matter is valid YAML
- Restart the development server
- Check that localStorage is enabled in your browser
- Clear browser cache and reload
- Check browser console for JavaScript errors
- Full-text search with filtering
- Comment system (Giscus)
- Related posts suggestions
- Reading time estimation
- Email newsletter signup
- Social media sharing buttons
- Analytics integration
This project is open source and available under the MIT License.
Created as a personal blog for PLC and industrial automation topics.
Start writing your PLC articles today! π