3 ms·
Thanks, that's a really helpful example. Where I think this could be taken to the next level of reusability is in modularising the front-end into API-specific
by eddsalkield 6y ago
Thanks, that's a really helpful example.
Where I think this could be taken to the next level of reusability is in modularising the front-end into API-specific components. For example, the login behaviour could depend on FastAPI-Users, with a sibling frontend library containing components that implement the same login flow. Adding user behaviour is then a matter of using the same third-party library on the front and back end.
This approach could be extended to other components such as an admin panel (perhaps using https://github.com/awtkns/fastapi-crudrouter https://github.com/awtkns/fastapi-crudrouter), or a blogging component.
- tiangolo 6y agoActually I also have plans to work on a generic admin UI based on OpenAPI, so it would be independent of any DB or ORM, just based on the defined Pydantic models. But that's also gonna be for whenever I get the time to invest in it :)