apache / airflow

Apache Airflow - A platform to programmatically author, schedule, and monitor workflows
https://airflow.apache.org/
Apache License 2.0
37.31k stars 14.34k forks source link

AIP-38 Programmatic form component #42372

Open pierrejeambrun opened 2 months ago

pierrejeambrun commented 2 months ago

Brent says:

Let's develop a robust form component that can render many different fields based on the spec it receives. Then we > can use this for advanced dagrun trigger and connection management.

Committer

jscheffl commented 1 month ago

I would try to raise my hand for this. Just need a bit time to get started in the new ecosystem :-D

THe components woul dbe needed for (1) trigger form as well as (2) connection for in the feature set of the legacy UI.

pierrejeambrun commented 1 month ago

Yes the idea is to have a generic form component, flexible, reusable enough to do any type of form. A good idea would be to take a look into react form libraries out there and find one that looks good. (input validation, error handling, etcc...). In the past I have used formik, I don't know if it is still relevant today or if other libraries are better suited such as https://tanstack.com/form/latest

bbovenzi commented 1 month ago

Updating my comment based on some quick research.

formik: https://formik.org/ Has had long periods of not being maintained, not typescript-first tanstack/form: https://tanstack.com/form/latest His other libraries, query and table, have been very useful for us, but its still at v0.33.0 so it could change a lot after a v1.0 react-hook-form: https://react-hook-form.com/ Another popular framework.

I would lean towards react-hook-form, idk if we want to rely on an outdated library or anything at a 0.X version

pierrejeambrun commented 1 month ago

I share the feeling for 0.X versions. This is something I mentioned when we considered switching the backend web framework, but still we went with FastAPI, so I would say for consistancy that 0.X version are not a problem for us. (I guess)

And in general tanstack lib are well done.