mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-19 07:06:30 +00:00
Support new panel generation (#487)
* Support new panel generation * fix lint
This commit is contained in:
parent
f361916a60
commit
124e487ef7
@ -202,8 +202,14 @@ class RestAPI(CoreSysAttributes):
|
||||
web.get('/panel_latest', create_response('hassio-main-latest')),
|
||||
])
|
||||
|
||||
# This route is for HA > 0.61
|
||||
self.webapp.add_routes([web.static('/app-es5', panel_dir)])
|
||||
# This route is for backwards compatibility with HA 0.62 - 0.70
|
||||
self.webapp.add_routes([
|
||||
web.get('/app-es5/index.html', create_response('index')),
|
||||
web.get('/app-es5/hassio-app.html', create_response('hassio-app')),
|
||||
])
|
||||
|
||||
# This route is for HA > 0.70
|
||||
self.webapp.add_routes([web.static('/app', panel_dir)])
|
||||
|
||||
async def start(self):
|
||||
"""Run rest api webserver."""
|
||||
|
Loading…
x
Reference in New Issue
Block a user