[web-devel] Yesod form composition
Michael Snoyman
michael at snoyman.com
Tue Jun 21 19:42:52 CEST 2011
Just in case people missed it, Doug (MightyByte) sent a link to how he
implemented this in digestive-functors[1].
I thought I'd spell it out on the list now, since I don't think I ever
explained this: I wanted to base yesod-form off of digestive-functors,
but its lack of custom forms was a problem. In yesod-form, we have
three styles of form: applicative, monadic and input. d-f only
supports applicative. I think a good medium-term strategy is for
yesod-form to develop as it has been, adding the features that are
necessary. When we feel comfortable with where it's at, I'd like to
touch base with the d-f team and see if we can figure out a way to get
these two libraries to work together.
Michael
[1] http://hackage.haskell.org/packages/archive/digestive-functors/0.1.0.0/doc/html/Text-Digestive-Forms.html#v:inputList
On Thu, Jun 16, 2011 at 10:16 PM, Greg Weber <greg at gregweber.info> wrote:
> rails: http://ryandaigle.com/articles/2009/2/1/what-s-new-in-edge-rails-nested-attributes
> django: https://docs.djangoproject.com/en/dev/topics/forms/formsets/
> I don't see why we can't have new helpers for generating and consuming a
> list of forms that operate the same as now but just map over a list instead.
> Django also shows techniques we might use to display the forms.
> Greg Weber
> On Thu, Jun 16, 2011 at 11:43 AM, Michael Snoyman <michael at snoyman.com>
> wrote:
>>
>> This is definitely something missing from the yesod-form API as is.
>> I'm not quite sure how the API would look for this; has anyone given
>> this some thought?
>>
>> On Wed, Jun 15, 2011 at 7:06 AM, Tyson Whitehead <twhitehead at gmail.com>
>> wrote:
>> > Hi All,
>> >
>> > I'm wanting to make a form for "[a]" by composing forms for "a" along
>> > with
>> > added a delete options and a final add another option.
>> >
>> > Is there an accepted way to do this sort of thing? It doesn't seem to
>> > me to
>> > be a good fit for the applicative framework as it is not a fixed
>> > structure.
>> >
>> > Cheers! -Tyson
>> >
>> > _______________________________________________
>> > web-devel mailing list
>> > web-devel at haskell.org
>> > http://www.haskell.org/mailman/listinfo/web-devel
>> >
>> >
>>
>> _______________________________________________
>> web-devel mailing list
>> web-devel at haskell.org
>> http://www.haskell.org/mailman/listinfo/web-devel
>
>
More information about the web-devel
mailing list