MarkLab is a web application for writing, previewing, storing, and exporting Markdown documents. Users can create an account, manage a private collection of documents, and work in a split editor with a live preview.
- Account registration, login, logout, and protected routes
- Private Markdown document workspace
- Create, list, edit, and delete documents
- Live Markdown preview and adjustable editor/preview layout
- Automatic saving after a short pause, plus
Ctrl/Cmd + Smanual saving - Export of the current document as
.mdor.txt - Persistent display preference and light/dark colour mode
- Framework: Nuxt 4 and Vue 3 with TypeScript
- UI: Nuxt UI and Tailwind CSS
- Database: PostgreSQL, accessed with Drizzle ORM and
postgres.js - Authentication: JWT (
jose) stored in an HTTP-only cookie; passwords hashed with Argon2 - Validation and state: Zod and Pinia
- Markdown: Nuxt MDC
- Platform integration: NuxtHub
The French technical documentation, prepared for a TPI-style school project and ready to be published with MkDocs, is available in docs/.
- Node.js 20 or newer
- A PostgreSQL database
Install the dependencies:
npm installCreate a .env file at the project root:
DATABASE_URL=postgresql://USER:PASSWORD@HOST:5432/DATABASE
JWT_SECRET=replace-with-a-long-random-secretApply the SQL migrations from server/db/migrations/postgresql/ to the target database before starting the application. The project currently does not expose a migration script in package.json.
Start the development server:
npm run devThe application is then available at http://localhost:3000.
| Command | Purpose |
|---|---|
npm run dev |
Start the development server. |
npm run build |
Create a production build. |
npm run preview |
Preview the production build locally. |
npm run generate |
Generate a static version of the application. |
app/ Vue pages, middleware, stores, composables, and UI assets
server/ API endpoints, business services, repositories, and database schema
server/db/migrations/ PostgreSQL migration history
docs/ French technical documentation for MkDocs
Never commit .env. It contains the database connection URL and the secret used to sign JWTs. The .gitignore file already excludes local environment files.