Do you have little tricks for getting the best out of the Chrome Dev tools?

I ran across this repo recently and I'm finding the (inspect) macro helpful:
https://github.com/shaunlebron/How-To-Debug-CLJS

Source maps are fantastic for jumping to the point of an exception and looking 
up the Call Stack.

Hovering the mouse over variables tries to show value but for CLJS data types 
kind of works but it's not as informative as it could be.  I find it useful 
create Watch Expressions which use pr-str but I'm interested to hear of better 
approaches.  

Watch Expression: cljs.core.pr_str(localvar)

I'd love a way to more easily do this for local variables and function 
arguments.  Not sure if this will work but I'm trying it today...  

Watch Expression:  cljs.core.pr_str(arguments)

It's often helpful to look at the state of an atom (om app) when debugging.  
For that I use a little helper which can be called from the console with 
myapp.core.app_state_js():

(defn ^:export app-state-js []
  (clj->js @app-state))

What are your goto moves?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.

Reply via email to