A modern web-based Twig template editor with real-time preview capabilities. This monorepo contains both the backend API and frontend application for creating, editing, and exporting PDF documents from Twig templates.
- Monaco Editor Integration: Professional code editor with Twig syntax highlighting
- Live Preview: Real-time template rendering as you type
- Template Management: Load and edit existing Twig templates
- Variable Support: JSON-based template variables with live editing
- PDF Generation: Generate PDF from Twig templates using Puppeteer
- Clone the repository:
git clone git@github.com:ademozay/pwig.git
cd pwig- Install dependencies for all apps:
npm i- Copy environment files:
cp apps/backend/.env.example apps/backend/.env
cp apps/frontend/.env.example apps/frontend/.envYou can either start the development server, or you can build and start the app.
- Start the development server (both backend and frontend):
npm run dev- Build and start the app (both backend and frontend):
npm startOpen your browser and navigate to http://localhost:5000