Tests and doc site can now run without node, using only
"lein figwheel". Tests and site are then re-run automatically
whenever a source file changes.
The doc site is now generated into "outsite/public", and can be
copied into the "gh-pages" branch with "make build-gh-pages".
"make push-gh-pages" builds the doc site and pushes it upstream
to the gh-pages branch there.
Generation of html pages is now handled completely in
ClojureScript, loaded from "bin/gen-site.js".
Link handling is a bit simplified.
The new names correspond to changes in React in 0.12.0.
Both render-component and render-component-to-string are kept for
backward compatibility.
Call React.render etc to avoid deprecation warnings from React.
Adds RCursor type: wraps Reagent's RAtom along with a path that provides focus into a specific part of that atom.
Adds reagent.ratom/cursor as a constructor for the RCursor type.
Adds reagent.core/cursor as the public API. This can be called with just a path, and returns a function that accepts a Reagent atom, or with both a path and an atom.
Dereferences of a cursor behave like get-in on the underlying atom with the specified path.
If you reset! a cursor, it behaves like a swap! assoc-in on the underlying atom. If swap! a cursor, it behaves like a swap! update-in on the underlying atom.
This is actually a bug in ClojureScript
(http://dev.clojure.org/jira/browse/CLJS-777). In regular Clojure a
`MultiFn` is `ifn?`, but in ClojureScript it wasn't. The bug is now
fixed
(525154f2a4)
but not yet released.
This code can be reverted after Reagent's ClojureScript version is
updated.
Previously, the first argument had to be a map, and the rest of the
arguments where passed as a vector as the second argument.
Now [my-comp foo...] generally behaves as (my-comp foo...).
Since `this` is no longer passed to component functions, add
current-component function.
Also change signatures of React callbacks, to reflect that arbitrary
arguments can be passed.
Remove set-props and replace-props for the same reason.
Add argv accessor and set-args instead.