r/FastAPI • u/rroa • Oct 07 '21
feedback request I wrote an alternative for the official FastAPI full stack project generator (more info in comment)
https://github.com/gaganpreet/fastapi-starter
16
Upvotes
r/FastAPI • u/rroa • Oct 07 '21
7
u/rroa Oct 07 '21
Hi, earlier this year I built a project using the official FastAPI full stack example. While working on my project, I realised that the FastAPI ecosystem has matured a lot since that template was created and many things that I ended up writing code for was already solved by others. And I didn't want to keep reinventing the wheel.
For my new projects, I wanted a boilerplate which utilised the ecosystem as much as possible. So how's the new template better than the official template?
The front-end uses React Admin, which automatically creates front-end interfaces from declarative react templates.
FastAPI Users provides user management models and routes instead of writing your own layer
FastAPI CRUD for automatically creating CRUD APIs from database schemas
For cases where React Admin isn't sufficient: integration with OpenAPI code generator which creates Typescript definitions from OpenAPI spec generated by OpenAPI.
Other goodies: Flask-like factory pattern, Github action for building docker images and testing, pre-commit hooks, Dependabot config