MarkMind PDF is a React/Vite markdown editor and live PDF-style preview tool. It supports markdown, tables, Mermaid diagrams, themed code blocks, document styling, and PDF export from the browser.
Install these before running the app locally:
- Node.js 20 or newer
- npm, included with Node.js
- Optional: Docker Desktop, only if you want to run the app in Docker
On Windows PowerShell, use npm.cmd if npm is blocked by the execution policy.
src/
components/ React preview and diagram components
services/ Gemini and PDF helpers
App.tsx Main application shell
index.tsx React entry point
types.ts Shared theme types
docker/
nginx.conf Production nginx config used by Docker
Dockerfile Production container build
docker-compose.yml
The app can run without an API key, but the AI styling feature requires a Gemini API key.
Create a .env.local file in the project root:
GEMINI_API_KEY=your_gemini_api_key_hereDo not commit .env.local.
Install dependencies:
npm installStart the dev server:
npm.cmd run devOpen the local URL printed by Vite. This project is configured to use:
http://localhost:3000
Create a production build:
npm.cmd run buildPreview the production build locally:
npm.cmd run previewDocker is optional. The normal Node/Vite workflow still works.
Install Docker Desktop for Windows:
winget install Docker.DockerDesktopAfter installing, open Docker Desktop once and verify:
docker --version
docker compose version
docker run hello-worldBuild and run the app:
docker compose up --buildOpen:
http://localhost:3000
To stop Docker:
docker compose downThe Gemini key is embedded during the Vite build. If you want AI styling to work inside Docker, set GEMINI_API_KEY before building.
PowerShell:
$env:GEMINI_API_KEY="your_gemini_api_key_here"
docker compose up --buildnpm install
npm.cmd run dev
npm.cmd run build
npm.cmd run preview
docker compose up --build
docker compose downIf PowerShell blocks npm, use:
npm.cmd run devIf port 3000 is already in use, stop the other process or change the port in vite.config.ts and docker-compose.yml.
If Docker commands fail, make sure Docker Desktop is running.
If AI Style does not work, confirm GEMINI_API_KEY is set before starting or building the app.
This project is licensed under the MIT License. You can use it for personal and commercial projects, but copies or substantial portions of the project must include the original copyright and license notice.