Commit f96c0d25 authored by Alex Beregszaszi's avatar Alex Beregszaszi

Remove instant updates from the url.hash

This wasn't fully working and would create a complex code (at least now)
parent 661d17fc
......@@ -53,15 +53,6 @@ var run = function () {
loadFiles(filesToLoad);
}
// ------------------ query params (hash) ----------------
function syncQueryParams () {
$('#optimize').attr('checked', (queryParams.get().optimize === 'true'));
}
window.onhashchange = syncQueryParams;
syncQueryParams();
// -------- check file upload capabilities -------
if (!(window.File || window.FileReader || window.FileList || window.Blob)) {
......@@ -531,6 +522,9 @@ var run = function () {
}
}
// set default
$('#optimize').attr('checked', (queryParams.get().optimize === 'true'));
document.querySelector('#optimize').addEventListener('change', function () {
queryParams.update({ optimize: document.querySelector('#optimize').checked });
compiler.compile();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment