refactor: Replace Rollup with Vite (#2656)

This is a high risk change: every byte the card ships is emitted by a
different bundler, minified by a different minifier, and every
stylesheet is compiled by a different sass. The intent is that the
card's behaviour is unchanged.

**Significant development win**: Build time drops from 24s to 1.1s 🎉 

Also adds a test suite ('dist') that runs against the built bundle.
This commit is contained in:
Dermot Duffy
2026-08-04 15:00:13 -07:00
committed by GitHub
parent 06bcfd58ba
commit 80ec92e3b2
105 changed files with 1273 additions and 1719 deletions
+10
View File
@@ -24,6 +24,16 @@ Resultant build entry file will be in `dist/advanced-camera-card.js`. This could
installed via the [manual installation
instructions](advanced-installation.md?id=manual-installation).
To rebuild as the source changes:
```sh
$ yarn start
```
This writes to `dist/` just like a normal build so that Home Assistant reading
the card from a path on disk picks each rebuild up. To have Home Assistant read
from a URL instead, use `yarn preview` which serves `dist/` on port 10001.
## Releasing
### Release Philosophy