All contributions are welcome! If you would like to make some changes, follow these steps:
- Fork the project and clone it.
- Install project dependencies:
Note: You might need to install yarn globally first with npm i -g yarn or by follow instructions at https://classic.yarnpkg.com/en/docs/install.
yarn- Copy
config.example.jstobuild/config.js(createbuilddirectory if necessary) and adjust options for your server:
- Change
serverUrlin the config to point to the Home Assistant URL. - Change
wsUrlin the config to point to the Home Assistant API (usewssinstead ofwsprotocol if HA is running on secure connection).
- Configure
http.cors_allowed_originssetting in Home Assistant to allow your server (e.g. localhost) to communicate with the HA API:
http:
cors_allowed_origins:
- http://<your-server>:8080This needs to be added in configuration.yaml in HA. See https://www.home-assistant.io/integrations/http/#cors_allowed_origins for more info.
- Start the development server:
yarn devThis starts a local development server at address http://localhost:8080, serving the built TileBoard.
Modifications to the project trigger an automatic rebuild to make it easy to iterate quickly.
To create an optimized release build of TileBoard run:
yarn buildThis creates optimized, smaller build that should be used when running TileBoard in "production". This command doesn't start development server.
Release builds are also attached to GitHub releases in "assets" section so if you are not planning to make any changes then you can use those instead.
A new release can be created by running yarn release. A new tagged commit will be created and pushed to the remote repo, triggering automatic creation of new release with built app package attached in "assets" section.