Clojurescript: converting cljs map to a javascript hash

clojurescript

Solution

cljs.core/js-obj should help for this. Please notice that it takes normal array/list in (not a map).

headerElement (goog.dom/createDom
               "div" (js-obj "style" "background-color:#EEE")
               (:title note))

Problem

The following code snippet does not work ``` headerElement (goog.dom/createDom "div" (.strobj {"style" "background-color:#EEE"}) (:title note)) ``` Reason: { ... } creates a Clojurescript map. I need a javascript object/hash. Question: How do I make this trivial conversion?

Original source