Fork me on GitHub
#hoplon
<
2017-06-21
>
thedavidmeister02:06:12

so is the idea that :on and :do are now much stricter about what data they will accept?

thedavidmeister02:06:40

e.g. :toggle could only accept a boolean?

flyboarder03:06:27

@thedavidmeister exactly, however the runtime specs are heavy so you turn them on for development and off for production, you can always use the new pre/post map support to check the arguments if you want them to run always

alandipert03:06:09

@flyboarder really impressive work you're doing there!

thedavidmeister04:06:28

@flyboarder that's pretty cool, i just wonder how many errors i will see as soon as i turn it on 😕

thedavidmeister04:06:41

also, the addition of spec.alpha means i will be forced to upgrade to the new ns

thedavidmeister04:06:52

so, there's going to be some hoop jumping to upgrade to this one

thedavidmeister04:06:11

@flyboarder also, how hard is it to turn them off in development?

jouerose07:06:17

@flyboarder sorry i did not understand

jouerose07:06:36

@flyboarder what you said about .target.files

cycle33709:06:12

hello #hoplon what's up?>

flyboarder15:06:47

@thedavidmeister really easy to turn it on just call hoplon.core/spec! on your index page, by default it's off. Clojure 1.9 will probably be released with alpha spec anyway but we will see. There are only about 100 issues remaining for 1.9 and most of them are for spec.

flyboarder15:06:34

@jouerose the event object you are receiving from the change event contains an original event object, which has a property called target, which has another property called files. This files property is the list you are looking for.

jjttjj16:06:48

This is driving me insane, might be a timbre thing instead of hoplon, but anyone know why timbre/error is working and logging to js console, but timbre/debug isn't showing anything? This is from a fresh hoplon template directory:

(page "index.html"
  (:require
   [taoensso.timbre :as timbre
    :refer-macros [log  trace  debug  info  warn  error  fatal  report
                   logf tracef debugf infof warnf errorf fatalf reportf
                   spy get-env]]))

;;(enable-console-print!)

(timbre/set-level! :trace)

(debug "hello world")
(error "error")


(html
  (head
    (link :href "app.css" :rel "stylesheet" :type "text/css"))
  (body
    (h1 "Hello, Hoplon!")))

flyboarder17:06:54

@jjttjj where are the logging levels documented? do you need the :debug level?

jjttjj17:06:44

Can't seem to find the documentation for levels, but I recall trace being lower than debug, and it doesn't work if i set the level to :debug either. This is probably more a Timbre issue than hoplon at this point though

flyboarder17:06:32

I would say so, I also can’t find the documentation for levels. But if debug doesn’t work either it’s probably timbre.