An ORM wrapper for mysql2 within the fastcar-core framework (v0.1.24). Provides structured entity-mapper patterns via decorators (@Table, @Field, @PrimaryKey) and integrates with fastcar-core's dependency injection (@Repository, @Autowired). Supports CRUD, raw SQL, multi-datasource, and slow query logging. Ships TypeScript types. Requires Node >=16 and peer dependencies fastcar-core, fastcar-timer, and nanoid (3.3.4). Key differentiator: tight coupling with the fastcar ecosystem for decorator-based data mapping and lifecycle management.
npm install fastcar-mysqlNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows minimal setup: enable mysql with decorator, define an entity, create a mapper, and inject into a service for querying.
Upgrade Node to v16 or higher.
Use correct import statements as documented.
Install nanoid@3.3.4 explicitly if using npm <7.
Add import 'reflect-metadata' at the top of your entry file.
Use 'import { EnableMysql } from "fastcar-mysql/annotation"' and ensure fastcar-mysql is installed.Install fastcar-core and fastcar-timer as peer dependencies.
Use import syntax instead of require().
Add "type": "module" to package.json or rename file to .mjs.