Ohm-Management - Projektarbeit B-ME
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

main.js 986B

123456789101112131415161718192021222324252627282930
  1. /******************************************************
  2. * Main JavaScript file - Entry point of all JS files *
  3. ******************************************************/
  4. // NOTE: ServiceWorker Registration
  5. if ('serviceWorker' in navigator) {
  6. window.addEventListener('load', function () {
  7. // Register a service worker hosted at the root of the
  8. // site using the default scope ('/').
  9. return navigator.serviceWorker.register('/serviceWorker.js', {
  10. scope: '/'
  11. }).then(function (registration) {
  12. return console.log('[ServiceWorker] Registration succeeded: ', registration);
  13. }).catch(function (error) {
  14. return console.log('[Service worker] Registration failed: ', error);
  15. });
  16. });
  17. } else {
  18. console.log('[ServiceWorker] are not supported.');
  19. }
  20. // NOTE: Set Bootstrap materialdesign
  21. document.addEventListener("DOMContentLoaded", function () {
  22. $('body').bootstrapMaterialDesign();
  23. }, false);
  24. /*
  25. $(document).ready(function() {
  26. $('body').bootstrapMaterialDesign();
  27. });
  28. */