toeg
v0.1.2
Published
Generates entities for TypeORM from a database
Downloads
2
Readme
Features
Generates entities for TypeORM from a databases. Supports PostgreSQL engine only, but can be extend using Abstract driver. Inspired by https://github.com/Kononnable/typeorm-model-generator (unfortunately not supported anymore). The fork was created to add two main features: skip indices and relations generation.
Usage
- Add
toeg
to your project
npm i -D toeg
Then create a configuration file
.toeg.json
using.toeg-example.json
as a base.And finally run
toeg
:
node_modules/.bin/toeg
The generated entity models aren't formatted well, so it's recommended to run prettify and eslint on generated modules:
prettier --write --loglevel error \"output/*.ts\" && eslint \"output/*.ts\" --fix --quiet
Licence
Licensed under the MIT license.
Author
Alexander Mac