Code formatting according to standardjs

This commit is contained in:
Stephan 2019-03-31 21:30:46 +02:00
parent e2bbe9273a
commit 3d4eef5eb0
10 changed files with 44 additions and 44 deletions

View file

@ -13,7 +13,7 @@
{% include "hippie/partials/_head_script.njk" %}
<script>
debugOn = true;
document.addEventListener('DOMContentLoaded', function() {
document.addEventListener('DOMContentLoaded', function () {
logPerf('Document \'DOMContentLoaded\' event fired.');
});
logPerf('On HEAD, starting...');

View file

@ -13,7 +13,7 @@
{% include "hippie/partials/_head_script.njk" %}
<script>
debugOn = true;
document.addEventListener('DOMContentLoaded', function() {
document.addEventListener('DOMContentLoaded', function () {
logPerf('Document \'DOMContentLoaded\' event fired.');
});
logPerf('On HEAD, starting...');

View file

@ -7,13 +7,13 @@ var assetsLoaded = false;
// Get the current time difference between page
// load and when this func was invoked
function getTimeDiff() {
function getTimeDiff () {
return new Date().getTime() - performance.timing.navigationStart;
}
// log message to console and add
// performance measuring information
function logPerf(msg) {
function logPerf (msg) {
if (debugOn) {
if (debugOnScreen && assetsLoaded) {
if (!$('#jsLogPerf').length) {