News for hackers. Stuff that matters.
Re:ClojureScript 101 by olifante on Tuesday November 12, 2013 @11:51AM (#6718880)
The (.log js/console (dom/getElement "query")) command returns "null" instead of a DOM element. Curiously, manually running the equivalent command in the Chrome console works as expected:

  > goog.dom.getElement
    function (element) {
      return goog.isString(element) ?
        document.getElementById(element) : element;
    }
  > goog.dom.getElement("query")
    <input id=​"query" type=​"text">​

There are no comments on this comment yet.