Fix custom panel doctype (#2977)

This commit is contained in:
Paulus Schoutsen 2019-03-20 07:36:28 -07:00 committed by GitHub
parent be9402bd05
commit b82a1c75c4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -98,7 +98,9 @@ It will have access to all data in Home Assistant.
`.trim();
const iframeDoc = this.querySelector("iframe").contentWindow.document;
iframeDoc.open();
iframeDoc.write(`<script src='${window.customPanelJS}'></script>`);
iframeDoc.write(
`<!doctype html><script src='${window.customPanelJS}'></script>`
);
iframeDoc.close();
}