Utilizar Otro ORM
The core of the framework is independent of TypeORM. So, if you do not want to use an ORM at all or use another ORM or ODM than TypeORM, you absolutely can.
To do so, you will have to remove TypeORM and all its utilities.
Uninstall TypeORM
-
First uninstall the dependencies.
npm uninstall typeorm @foal/typeorm -
Then remove the directory
src/app/entitiesand the filesrc/db.ts. -
Remove or replace the script
create-userinsrc/app/scripts. -
In the file
src/index.ts, delete the connection creation calleddataSource.initialize(). -
Finally, remove in
package.jsonthe scripts to manage migrations.
Examples
Limitations
When using another ORM than TypeORM some features are not available:
- the Groups & Permissions system,
- and the
foal g rest-apicommand.