93 lines
1.5 KiB
Markdown
93 lines
1.5 KiB
Markdown
# Markdown Blog
|
|
|
|
A modern blog system built with Next.js, Markdown, and Electron for cross-platform support.
|
|
|
|
## Features
|
|
|
|
- Write blog posts in Markdown
|
|
- Responsive web design
|
|
- Desktop application support via Electron
|
|
- Mobile-friendly interface
|
|
- Tag-based organization
|
|
- Clean and modern UI
|
|
|
|
## Getting Started
|
|
|
|
### Prerequisites
|
|
|
|
- Node.js 18+ and npm
|
|
|
|
### Installation
|
|
|
|
1. Clone the repository:
|
|
```bash
|
|
git clone <repository-url>
|
|
cd markdownblog
|
|
```
|
|
|
|
2. Install dependencies:
|
|
```bash
|
|
npm install
|
|
```
|
|
|
|
3. Start the development server:
|
|
```bash
|
|
npm run dev
|
|
```
|
|
|
|
4. For desktop development:
|
|
```bash
|
|
npm run electron-dev
|
|
```
|
|
|
|
### Writing Posts
|
|
|
|
Create new blog posts by adding Markdown files to the `posts/` directory. Each post should include frontmatter with the following fields:
|
|
|
|
```markdown
|
|
---
|
|
title: "Your Post Title"
|
|
date: "YYYY-MM-DD"
|
|
tags: ["tag1", "tag2"]
|
|
summary: "A brief summary of your post"
|
|
---
|
|
|
|
Your post content here...
|
|
```
|
|
|
|
### Building for Production
|
|
|
|
1. Build the web version:
|
|
```bash
|
|
npm run build
|
|
```
|
|
|
|
2. Build the desktop version:
|
|
```bash
|
|
npm run electron-build
|
|
```
|
|
|
|
## Project Structure
|
|
|
|
```
|
|
markdownblog/
|
|
├── posts/ # Markdown blog posts
|
|
├── src/
|
|
│ ├── app/ # Next.js app directory
|
|
│ └── lib/ # Utility functions
|
|
├── electron/ # Desktop app code
|
|
└── public/ # Static assets
|
|
```
|
|
|
|
## Technologies Used
|
|
|
|
- Next.js 14
|
|
- TypeScript
|
|
- Tailwind CSS
|
|
- Electron
|
|
- Markdown (remark)
|
|
- date-fns
|
|
|
|
## License
|
|
|
|
MIT |