Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-06-14 Thread Mark Hamburg
Thanks, Peter. You got there ahead of me (thereby saving me from writing an example). > Jun 14, 2016, at 8:47 AM, Peter Damoc wrote: > > Here is a version of the CounterList with Context. It mimics how the old > Address context used to work. > > https://github.com/pdamoc/elm-architecture-tu

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-06-14 Thread Peter Damoc
Here is a version of the CounterList with Context. It mimics how the old Address context used to work. https://github.com/pdamoc/elm-architecture-tutorial/tree/master/examples/4b The main idea behind this approach is that the resulting view needs to talk in the language of the parent so, each Con

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-06-14 Thread Adam Waselnuk
Mark would you be able to provide a link to that solution you are talking about here? On Wednesday, May 18, 2016 at 4:40:07 PM UTC-4, Mark Hamburg wrote: > > I'm hoping that's not how it is expected to work because it means that a > view layout decision — we need to put the remove button in with

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-05-18 Thread Mark Hamburg
Or more succinctly, the issue to be dealt with in the counter with remove button case is that the view needs to be able to "send" more messages not that the counter update function needs to handle more messages. Mark > On May 18, 2016, at 1:40 PM, Mark Hamburg wrote: > > I'm hoping that's not

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-05-18 Thread Mark Hamburg
I'm hoping that's not how it is expected to work because it means that a view layout decision — we need to put the remove button in with the counter display and buttons — now spreads to the messages and update function. I much prefer the solution that someone else posted where viewWithRemove tak

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-05-18 Thread Homan Chou
Interesting... it's like it's own module. I feel like there are a lot of little things like this that aren't covered in any of the getting started guides. On Wed, May 18, 2016 at 1:05 PM, Peter Damoc wrote: > It means that it exports both the type Dispatch and the tag Remove. It's > explicit wi

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-05-18 Thread Peter Damoc
It means that it exports both the type Dispatch and the tag Remove. It's explicit with what it exports. It should have been "Dispatch(..)" because in cases like this you might want to expose all the Dispatch Tags. On Wed, May 18, 2016 at 10:55 PM, Homan Chou wrote: > Ah... thanks. I read that

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-05-18 Thread Homan Chou
Ah... thanks. I read that wrong and thought you were linking the old repo. What does "Dispatch(Remove)" mean in the Counter exposing part? On Tue, May 17, 2016 at 10:54 PM, Peter Damoc wrote: > It works like you can see in the second link you've quoted. :) > > > > > On Wed, May 18, 2016 at 8:4

Re: [elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-05-17 Thread Peter Damoc
It works like you can see in the second link you've quoted. :) On Wed, May 18, 2016 at 8:40 AM, Homan Chou wrote: > Hi Brian, >> The Elm Architecture Tutorial has a "nesting" example: >> https://github.com/evancz/elm-architecture-tutorial/tree/master/nesting >>

[elm-discuss] Re: How do I render a child component in 0.17 (like CounterList)?

2016-05-17 Thread Homan Chou
> > Hi Brian, > The Elm Architecture Tutorial has a "nesting" example: > https://github.com/evancz/elm-architecture-tutorial/tree/master/nesting >