lambdaisland 2017-07-01

@sakalli has joined the channel

@plexus using the reagent tutorial from lambdaisland to get going building a slideshow app. a little bit stuck here trying to pass the state atom to the render function. the chestnut reagent template is changed since you did the tutorial i suspect. it now includes stuartsierras components and needs a render function defined. any pointers how to get it to work?

@sakalli are you able to push your code to Github? I need a bit more context to see what to do...

not much code yet following the kanban tutorial but hacking to my needs, can paste a snippet here.

which flags did you pass to chestnut? are you using +reagent?

I should probably update the transcript on those episodes to use a locked version of Chestnut

it's basically the same though, except that render is now wrapped in a method

(ns sesame.core
  (:require [reagent.core :as r]))

(def app-state
  (r/atom ,,,))

,,,

(defn Board [state]
  [:div.board
   (for [c (:columns @state)]
     [Column c])
   [NewColumn]])

(defn render []
  (r/render [Board app-state] (js/document.getElementById "app")))

ok cheer! got it to work now. just a typo. thanks for your help!

sorry for the inconvenience.

you're welcome! good luck with your app 😄

used the --reagent flag