diff options
author | Thomas Lange <code@nerdmind.de> | 2015-04-15 21:29:19 +0200 |
---|---|---|
committer | Thomas Lange <code@nerdmind.de> | 2015-04-15 21:29:19 +0200 |
commit | bf996f7247133c536511c23b6ad30aa222bfd6d9 (patch) | |
tree | 1d9388e6331454fbc9b68b5006a64c4563c202cd /static/bigpipe-callbacks.js | |
download | bigpipe-bf996f7247133c536511c23b6ad30aa222bfd6d9.tar.gz bigpipe-bf996f7247133c536511c23b6ad30aa222bfd6d9.tar.xz bigpipe-bf996f7247133c536511c23b6ad30aa222bfd6d9.zip |
Initial commit
Diffstat (limited to 'static/bigpipe-callbacks.js')
-rwxr-xr-x | static/bigpipe-callbacks.js | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/static/bigpipe-callbacks.js b/static/bigpipe-callbacks.js new file mode 100755 index 0000000..a9f48f1 --- /dev/null +++ b/static/bigpipe-callbacks.js @@ -0,0 +1,27 @@ +// Folgende Phasen stehen zur Auswahl: PAGELET_STARTED, RESOURCE_DONE, PAGELET_HTML_RENDERED, PAGELET_JS_EXECUTED und BIGPIPE_PAGELETS_RENDERED + +var debugLine = "------------------------------------------------------------------------------------------------------------------------"; + +BigPipe.registerPhaseDoneCallback('PAGELET_STARTED', function(Pagelet) { + console.log(debugLine); + console.log(Pagelet.pageletID + ":\t" + "Die Ausführung des Pagelets wurde gestartet."); +}); + +BigPipe.registerPhaseDoneCallback('RESOURCE_DONE', function(Resource) { + console.log(Resource.pageletID + ":\t" + 'Die Ressource ' + Resource.file + ' wurde geladen.'); +}); + +BigPipe.registerPhaseDoneCallback('PAGELET_HTML_RENDERED', function(Pagelet) { + console.log(Pagelet.pageletID + ":\t" + 'Die Platzhalter wurden mit HTML-Code befüllt.'); +}); + +BigPipe.registerPhaseDoneCallback('BIGPIPE_PAGELETS_RENDERED', function() { + console.log(debugLine); + console.log('BP' + ":\t" + 'Die Platzhalter von allen Pagelets wurden mit ihrem HTML-Code befüllt.'); + console.log(debugLine); +}); + +BigPipe.registerPhaseDoneCallback('PAGELET_JS_EXECUTED', function(Pagelet) { + console.log(Pagelet.pageletID + ":\t" + 'Der zugehörige Javascript-Code des Pagelets wurde ausgeführt.'); + console.log(debugLine); +});
\ No newline at end of file |