Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dash Core components auto generate #14

Open
kaashyapan opened this issue Jun 3, 2021 · 3 comments
Open

Dash Core components auto generate #14

kaashyapan opened this issue Jun 3, 2021 · 3 comments

Comments

@kaashyapan
Copy link
Contributor

Does there exist an interface definition file of some kind from which the Dash core components are auto generated for Python & Julia ?

I can see the props here https://dash.plotly.com/dash-core-components/textarea.
Is there a json or yaml file etc.. that is used by Python / Julia ?

@alexcjohnson
Copy link
Collaborator

The way this works today is first a JS script calls react-docgen to extract the prop info, then in Python we read that information in and generate matching source code for all the back ends. The ideal would be for .NET to add to this, such that npm run build:backends that every component package defines would create .NET bindings as well.

@mungojam
Copy link

mungojam commented Sep 4, 2021

I don't know if it would work or help, but you could consider source generators for this which are a standard way to generate code at .net build time

@kaashyapan
Copy link
Contributor Author

Source generators are C#. The aim of this project is to base it on F# with an easy to use api from C#.
Ideal route would be a simple F# script that reads the output of react-docgen and generates F# similar to the Feliz api for eacg component.

But I think it would help if we hand code the api to idiomatic F# first and automate generation after it has crystallised.

There is some work being done in
#19 & #16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants