Explorar o código

add demo.js reminder if not loaded via browserSync

REJack %!s(int64=3) %!d(string=hai) anos
pai
achega
e6139c15de
Modificáronse 1 ficheiros con 7 adicións e 0 borrados
  1. 7 0
      dist/js/demo.js

+ 7 - 0
dist/js/demo.js

@@ -10,6 +10,13 @@
 (function ($) {
   'use strict'
 
+  setTimeout(() => {
+    if (window.___browserSync___ === undefined) {
+      // eslint-disable-next-line no-alert
+      alert('You load AdminLTE\'s "demo.js", \nthis file is only created for testing purposes!')
+    }
+  }, 1000)
+
   function capitalizeFirstLetter(string) {
     return string.charAt(0).toUpperCase() + string.slice(1)
   }