Skip to content

A modern and feature-rich Markdown editor and previewer built with React and Vite. Features real-time preview, dark/light themes, auto-save, file import/export, and multiple preview styles.

License

Notifications You must be signed in to change notification settings

melihdemirdev/markdown-previewer

Repository files navigation

πŸ“ Markdown Previewer

Netlify Status PWA Ready Accessibility Score License: MIT

A sleek and modern markdown editor and previewer built with React + Vite ⚑

React Vite TailwindCSS

πŸ“Έ Screenshots

🌞 Light Mode

Light Mode

🌚 Dark Mode

Dark Mode

✨ Features

  • πŸŒ“ Dark/Light mode with smooth transitions
  • πŸ’Ύ Real-time auto-save
  • πŸ“± Fully responsive design for all devices
  • πŸš€ Live markdown preview
  • 🎨 Multiple preview styles (Default, GitHub, Elegant)
  • πŸ“‹ Import/Export markdown files
  • ⚑ Lightning-fast performance with Vite
  • 🎯 Customizable settings
  • πŸ“Š Optional line numbers
  • πŸ”„ Auto-save functionality
  • πŸ“± PWA support for native app experience
  • β™Ώ Full accessibility support with ARIA labels
  • πŸ”Œ Offline functionality
  • πŸ“² Install on any device
  • 🎨 Adaptive interface
  • πŸ€– NEW! Gemini AI Assistant for writing assistance

πŸš€ Live Demo

Try it out: WebMarkdown

πŸ› οΈ Tech Stack

  • Frontend Framework: React 18.3
  • Build Tool: Vite 6.0
  • Styling: Tailwind CSS 3.4
  • PWA: Vite PWA Plugin
  • AI: Google Gemini API
  • Key Dependencies:
    • 🎨 @heroicons/react
    • πŸ“ react-markdown
    • ✨ remark-gfm
    • 🎯 PropTypes
    • πŸ“± vite-plugin-pwa
    • πŸ€– @google/generative-ai

πŸ’» Local Development

  1. Clone the repository:
git clone https://github.com/melihcanndemir/markdown-previewer.git
  1. Install dependencies:
npm install
  1. Start the development server:
npm run dev
  1. Build for production:
npm run build

πŸ€– Gemini AI Setup (Optional)

To enable the AI Assistant feature:

  1. Get your free API key from Google AI Studio

  2. Create a .env file in the root directory:

cp .env.example .env
  1. Add your API key to the .env file:
VITE_GEMINI_API_KEY=your_actual_api_key_here
  1. Restart the development server

AI Assistant Features:

  • Improve Writing: Enhance clarity and professionalism
  • Fix Grammar: Correct spelling and punctuation
  • Summarize: Create concise summaries
  • Expand: Add more details and explanations
  • Translate: Turkish ↔ English translation
  • Custom Prompts: Use your own AI instructions

Note: The AI Assistant button will appear in the toolbar once the API key is configured.

🎯 Usage

Editor Features

  • Write markdown in the left panel
  • See instant preview in the right panel
  • Toggle dark/light mode with the theme button
  • Use the settings button to customize your experience

PWA Features

  • Install as a native app
  • Work offline
  • Fast loading times
  • Home screen installation
  • App-like experience

Accessibility Features

  • Full keyboard navigation
  • ARIA labels for all interactive elements
  • High contrast mode support
  • Screen reader friendly
  • Focus management

Import/Export

  • Click Import to load .md files
  • Click Export to save your work
  • Supports local storage auto-save

Settings

  • Adjust font size
  • Choose preview style
  • Toggle line numbers
  • Enable/Disable auto-save
  • Customize PWA behavior

πŸ“± Responsive Design

Optimized for all devices:

  • πŸ’» Desktop
  • πŸ“± Tablets (including iPad Air)
  • πŸ“± Foldable devices (including Zenbook Fold)
  • πŸ“± Mobile phones

🀝 Contributing

Contributions are welcome! Feel free to:

  1. Fork the repository
  2. Create your feature branch
  3. Submit a Pull Request

πŸ“œ License

This project is open source and available under the MIT License.

πŸ™ Credits

πŸ‘¨β€πŸ’» Author


Made with ❀️ by Melih Can Demir

About

A modern and feature-rich Markdown editor and previewer built with React and Vite. Features real-time preview, dark/light themes, auto-save, file import/export, and multiple preview styles.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published

Contributors 2

  •  
  •  

Languages