<commit_before>(ns om-animation-playground.core
  (:require [om.core :as om  :include-macros true]
            [om.dom  :as dom :include-macros true])
  (:require-macros [om-utils.core :refer [defcomponent]]))

(enable-console-print!)

(def app-state (atom {:tick 0}))

(defcomponent app
  (render
   (dom/div nil (:tick data))))

(defn app-loop-tick
  []
  (swap! app-state update-in [:tick] inc))

(defn init-app-loop
  [time]
  (.setInterval js/window #(app-loop-tick) time))

(defn init!
  []
  (om/root
   app
   app-state
   {:target (. js/document (getElementById "my-app"))})
  (init-app-loop 300))

(init!)
<commit_msg>Show multiples<commit_after>(ns om-animation-playground.core
  (:require [om.core :as om  :include-macros true]
            [om.dom  :as dom :include-macros true])
  (:require-macros [om-utils.core :refer [defcomponent]]))

(enable-console-print!)

(def app-state (atom {:tick 0}))

(defn multiples
  [upper-limit]
  (reduce (fn [acc n]
            (if (= (mod upper-limit n) 0)
              (conj acc n)
              acc))
          []
          (range 2 (inc upper-limit))))

(defcomponent app
  (render
   (let [{:keys [tick]} data]
     (dom/div nil (str (multiples tick))))))

(defn app-loop-tick
  []
  (swap! app-state update-in [:tick] inc))

(defn init-app-loop
  [time]
  (.setInterval js/window #(app-loop-tick) time))

(defn init!
  []
  (om/root
   app
   app-state
   {:target (. js/document (getElementById "my-app"))})
  (init-app-loop 500))

(init!)

{'fraction_non_alphanumeric': 0.17768871075484302, 'fraction_numerical': 0.006680026720106881, 'mean_word_length': 2.8608247422680413, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5815622', 'n_tokens_mistral': 577, 'n_tokens_neox': 556, 'n_words': 138}