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

Should we bundle HA provided dependencies? #53

Open
nathan-gs opened this issue Jun 4, 2024 · 2 comments
Open

Should we bundle HA provided dependencies? #53

nathan-gs opened this issue Jun 4, 2024 · 2 comments

Comments

@nathan-gs
Copy link
Owner

Currently we include leaflet and lit in our generated map-card.js, I wonder if it would be better to leave them out given HomeAssistant provides these anyway.

WDYT @thybag?

@thybag
Copy link
Contributor

thybag commented Jun 4, 2024

It'd probably be nice if we could find a way to do it, as Leaflets quite a bit of the code weight.
HA's code splitting tends to make it hard to request specific resources when their internal component isn't on the page so unsure if will be possible. So far as i could see there were very few custom map cards (Aside from your own) out there, otherwise would be tempted to have a peak at how they'd done it.

@nathan-gs
Copy link
Owner Author

I believe leaflet can be included directly (as we did before), lit is relatively small.

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

No branches or pull requests

2 participants