1
0
mirror of https://github.com/writeas/htmlhouse synced 2025-07-18 21:08:16 +00:00

Fix <script> breaking editor

This commit is contained in:
Christian Genco 2017-06-07 19:27:41 -05:00 committed by GitHub
parent 0ab4c7fc43
commit 8a2cdbd722

View File

@ -62,7 +62,11 @@
var hasBuilt = houses.length > 0;
function updatePreview() {
var val = editor.getSession().getValue();
$view.contents().find('body').html(val);
try {
$view.contents().find("body").html(val);
} catch (err) {
console.error(err);
}
{{if .ID}}{{else}}if (val != orig) {
publishing = false;
$publishBtn.removeClass("no");