A modern, full-stack web application boilerplate built with SvelteKit 5, Prisma, and Foundation Sites. This template provides a solid foundation for building scalable web applications with authentication, database integration, and modern UI components.
Clone the repository:
git clone https://github.com/maietta/SvelteKit-Prisma-Foundation-Boilerplate.git
cd SvelteKit-Prisma-Foundation-Boilerplate
Install dependencies:
npm install
Set up environment variables:
cp .env.example .env
Edit .env
with your configuration values.
Set up the database:
npx prisma migrate dev
Start the development server:
npm run dev
Create a .env
file with the following variables:
# Database
DATABASE_URL="mysql://user:password@localhost:3306/dbname"
# Authentication
JWT_SECRET="your-secret-key"
# Contact Form
SENDGRID_API_KEY="your-sendgrid-api-key"
EMAIL_DESTINATION="[email protected]"
EMAIL_REPLY_TO="[email protected]"
# reCAPTCHA
PUBLIC_RECAPTCHA_V3_SITE_KEY="your-site-key"
RECAPTCHA_V3_SECRET_KEY="your-secret-key"
โโโ src/
โ โโโ lib/
โ โ โโโ components/ # Reusable UI components
โ โ โโโ foundation/ # Foundation Sites configuration
โ โ โโโ utils/ # Utility functions
โ โโโ routes/
โ โ โโโ (auth)/ # Authentication routes
โ โ โโโ (dashboard)/ # Protected dashboard routes
โ โ โโโ contact/ # Contact form route
โ โโโ app.html # Base HTML template
โโโ prisma/
โ โโโ schema.prisma # Database schema
โโโ static/ # Static assets
npm run dev
- Start development servernpm run build
- Build for productionnpm run preview
- Preview production buildnpm run check
- Type-check the codebasenpm run test
- Run E2E testsnpm run test:unit
- Run unit testsnpm run lint
- Lint the codebasenpm run format
- Format the codebaseThis project can be deployed to various platforms:
For Vercel deployment:
git checkout -b feature/amazing-feature
)git commit -m 'Add some amazing feature'
)git push origin feature/amazing-feature
)This project is licensed under the MIT License - see the LICENSE file for details.