TypeScript Starter Pack for FiveM
A comprehensive TypeScript boilerplate for FiveM development with modern tooling, type safety, and best practices.
๐ Quick Start
Prerequisites
Node.js (v16 or higher)
Yarn package manager
FiveM server
Installation
Clone or download this starter pack
Navigate to the project directory
Install dependencies:
yarn
Development Commands
yarn build- Build TypeScript files to JavaScriptyarn dev- Build and obfuscate files for productionyarn watch- Auto-build TypeScript files (development mode)
๐ Project Structure
๐ง TypeScript Configuration
Type References
IMPORTANT: Add the appropriate type reference at the top of every file:
For client-side files:
For server-side files:
This enables IntelliSense and type checking for FiveM native functions.
๐ฏ Key Features
Type Safety: Full TypeScript support with FiveM native types
Modern Tooling: Yarn, ESLint, and Prettier configuration
Hot Reload: Automatic compilation during development
Production Ready: Obfuscation and optimization for deployment
Modular Structure: Organized codebase with clear separation of concerns
๐ Global Types
All global variables, interfaces, and types are defined in types/*.d.ts file.
You can extend this file to add your own global types and interfaces.
๐ค Contributing
Feel free to submit issues, feature requests, or pull requests to improve this starter pack.
๐ License
This project is open source and available under the MIT License.
Last updated