fivem-ts-svelte-boilerplate Svelte Themes

Fivem Ts Svelte Boilerplate

A FiveM Boilerplate using TypeScript Client- / Serverside and Svelte for UI

FiveM - TypeScript meets Modularity with Svelte5 in a dockerized FxServer

✨ Features

Blazing-Fast Build Pipeline - With Instant Change Detection! ⚑
Svelte 5 - For Next-Level Performance πŸš€
Seamless Database - Using Prisma ✨
Plug & Play Simplicity – Fully Dockerized! 🐳
Optimized Architecture – Bundled Server & Client with a Shared Core πŸ“¦
Powerful & Scalable – Clean Dependency Injection via Inversify πŸ—οΈ
Consistent & OOP-Driven – Leveraging NativeWrappers for Seamless Integration πŸ”₯

🎯 Getting Started

pnpm run build
# If you want your FXServer to be dockerized πŸ‹
docker compose up

πŸ’‘ Understanding

Structure

Serverside under src/server

Clientside under src/client

Shared under src/shared*
*make sure you only import content that is available on both sides. One hint is the API set: shared visible at the top right of https://docs.fivem.net/natives.

NUI under src-nui

Dependency Injection (Inversify)

Why?
Your code doesn’t create dependencies directly. Instead, it requests them, and Inversify provides the right ones at the right time. This approach makes your code more flexible, easier to test, and better organized.

Check out the official example https://inversify.io/docs/introduction/getting-started/

✏️ Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

πŸ’Ό License

MIT

Top categories

Loading Svelte Themes