home-assistant-frontend/cast
Jeremy Noesen 05e2e305e4
Update cast launch screen colors (#19754)
2024-03-04 15:45:54 +01:00
..
public Update cast idle logo (#19443) 2024-01-18 17:05:25 +01:00
script Tweak upload script 2019-08-06 09:56:07 -07:00
src Update cast launch screen colors (#19754) 2024-03-04 15:45:54 +01:00
README.md Align styling cast buttons (#3579) 2019-09-03 12:56:11 +02:00
rollup.config.js Make module types explicit and convert some to ESM (#15964) 2023-03-30 11:23:43 +02:00
webpack.config.js Make module types explicit and convert some to ESM (#15964) 2023-03-30 11:23:43 +02:00

README.md

Home Assistant Cast

Home Assistant Cast is made up of two separate applications:

  • Chromecast receiver application that can connect to Home Assistant and display relevant information.
  • Launcher website that allows users to authorize with their Home Assistant installation and launch the receiver app on their Chromecast.

Development

Setting up development environment

Registering development cast app

Setting dev variables

Open src/cast/dev_const.ts and change CAST_DEV_APP_ID to the ID of the app you just created. And set the CAST_DEV_HASS_URL to the url of you development machine.

Changing configuration

In configuration.yaml, configure CORS for the HTTP integration:

http:
  cors_allowed_origins:
    - https://cast.home-assistant.io
    - http://IP-OF-DEV-MACHINE:8080

Running development

cd cast
script/develop_cast

The launcher application will be accessible at http://localhost:8080 and the receiver application will be accessible at http://localhost:8080/receiver.html (but only works if accessed by a Chromecast).

Developing cast widgets in HA ui

If your work involves interaction with the Cast parts from the normal Home Assistant UI, you will need to have that development script running too (script/develop).

Developing the cast demo

The cast demo is triggered from the Home Assistant demo. To work on that, you will also need to run the development script for the demo (script/develop_demo).