Refactor dev-info page (#2624)

* Refactor dev-info page

* What

* Fix custom UI check

* Apply suggestions from code review

Co-Authored-By: balloob <paulus@home-assistant.io>

* Apply suggestions from code review

Co-Authored-By: balloob <paulus@home-assistant.io>

* Address comments

* TSC

* Apply suggestions from code review

Co-Authored-By: balloob <paulus@home-assistant.io>

* TSC
This commit is contained in:
Paulus Schoutsen
2019-01-29 15:34:49 -08:00
committed by GitHub
parent 73b500db64
commit c964ea30e0
11 changed files with 574 additions and 476 deletions

13
src/data/system_log.ts Normal file
View File

@@ -0,0 +1,13 @@
import { HomeAssistant } from "../types";
export interface LoggedError {
message: string;
level: string;
source: string;
// unix timestamp in seconds
timestamp: number;
exception: string;
}
export const fetchSystemLog = (hass: HomeAssistant) =>
hass.callApi<LoggedError[]>("GET", "error/all");