This repository demonstrates how to build a scalable and modular application using SvelteKit and tRPC. The project is structured to promote maintainability, separation of concerns, and ease of scalability.
Full Tutorial Here: Ultimate Guide to SvelteKit tRPC: Build Scalable, High-Performance Apps
This project serves as a foundation for building scalable apps using SvelteKit and tRPC. It demonstrates best practices for structuring large projects and includes a functional example of fetching and displaying coffee data.
Follow these steps to set up the project locally:
Ensure you have the following installed on your machine:
git clone https://github.com/michaelbelete/Sveltekit-tRPC.git
cd Sveltekit-tRPC
npm install
npm run dev
http://localhost:5173
The project is organized as follows:
src/
├── lib/ # Shared utilities and components
├── routes/ # SvelteKit pages and endpoints
├── server/ # Backend logic and tRPC setup
│ ├── routers/ # tRPC routers
│ ├── services/ # Business logic services
│ ├── validations/ # Zod validation schemas
Contributions are welcome! If you’d like to contribute:
git checkout -b feature-name
git commit -m "Add feature"
git push origin feature-name
This project is licensed under the MIT License. See the LICENSE file for details.