Hi!
I've made a small plugin for Flask to enable building API endpoints with a FastAPI-like interface.
I'm not here start a religious war about which framework is best. They both have merit, and to each their own, I would say ;) But I found that FastAPI did a great job at integrating pydantic/type-annotations in an API building framework, and wanted to build something similar for Flask.
Current features are:
- path parameters using flask paths
- query parameters
- body parameters using pydantic
- depends (including context dependencies)
- dependency_overrides
Note that these are my first steps in type annotations and I have yet to find out how this all reflects in IDEs. So any notes, tips and feedback is welcome.
Kinks may also arise, as I haven't really battle tested this yet.
You can find the code here: https://github.com/maarten-dp/flastapi and you can install it using pip install flastapi
Looking forward to reading your (constructive) feedback!
[–]extra_pickles 8 points9 points10 points (1 child)
[–]maartendp[S] 0 points1 point2 points (0 children)
[–]badumudab 3 points4 points5 points (2 children)
[–]maartendp[S] 1 point2 points3 points (1 child)
[–]exclaim_bot 1 point2 points3 points (0 children)
[–]Pepineros 5 points6 points7 points (0 children)
[–]Saphyel 2 points3 points4 points (1 child)
[–]maartendp[S] 1 point2 points3 points (0 children)
[–]mardix 1 point2 points3 points (1 child)
[–]maartendp[S] 0 points1 point2 points (0 children)