         (when-let [elements (not-empty (->Array (.querySelectorAll js/document (:selector conf))))]
           (doseq [element elements]
             (.addEventListener element (:on conf) (fn [e] (gtag (:requst conf) (:on conf) (:vars conf))))))
-        "visible" (println ">>>> " (:request conf))
+        "visible" (alert! ">>>> " (:request conf))
         (.addEventListener js/document (:on conf) (fn [e] (gtag (:requst conf) (:on conf) (:vars conf))))))))
       ; (if (= "click" (:on conf))
       ;   (when-let [elements (not-empty (->Array (.querySelectorAll js/document (:selector conf))))]

(set! js/dataLayer (if (exists? js/dataLayer) js/dataLayer (clj->js [])))

(defn gtag [& args]
  (println args)
  (.push js/dataLayer (clj->js args)))


(defn analytics-setup [data]
  (gtag "js" (clj->js (js/Date.)))


(enable-console-print!)

(defn alert! [what]
  (do (println what)
      (.log js/console what)))

(defn online-status [e]
  (alert! (if (.-navigator.onLine js/self) "ONLINE!" "OFFLINE!")))


(defn is-service-worker-supported? []
