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

investigate ways to reduce bundle size #3050

Open
gvwilson opened this issue Oct 22, 2024 · 1 comment
Open

investigate ways to reduce bundle size #3050

gvwilson opened this issue Oct 22, 2024 · 1 comment
Labels
feature something new P2 considered for next cycle performance something is slow

Comments

@gvwilson
Copy link
Contributor

The dash bundle is approx. 1o Mbyte, which will be a problem for WASM deploys. We should investigate ways to reduce its size.

cf. plotly/plotly.py#4817

@gvwilson gvwilson added feature something new P2 considered for next cycle performance something is slow labels Oct 22, 2024
@ndrezn
Copy link
Member

ndrezn commented Nov 12, 2024

Dash has several required dependencies:

Flask>=1.0.4,<3.1
Werkzeug<3.1
plotly>=5.0.0
dash_html_components==2.0.0
dash_core_components==2.0.0
dash_table==5.0.0
importlib-metadata
typing_extensions>=4.1.1
requests
retrying
nest-asyncio
setuptools

Simplifying this dependency list would be nice, and several dependencies are stubs.

Another strategy would be to asynchronously load bundles for dash_html_components, dash_core_components, and dash_table only when they are imported rather than requiring they be downloaded at all times. While dcc and html are more commonly used, making dash_table a lazy import would have a noticeable impact on performance in most cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature something new P2 considered for next cycle performance something is slow
Projects
None yet
Development

No branches or pull requests

2 participants