[web-devel] missing web component needed: server-side page control
jeremy at n-heptane.com
Tue Jun 22 15:39:26 EDT 2010
I have been experimenting with a Widget system based on HSX+HJScript.
The biggest issue I have run into seems to be marshaling your data
offer fairly different and incompatible data representations. But you
and server (Haskell).
You have 5 choices, that I can think of:
1. Use nice algebraic types. This makes your Haskell code nice, but
easier to work with, but is a type mess in Haskell and not easy to
makes the data easy to work with in both language, but you have to be
able to convert from one style to another. In my opinion, that
requires writing both representations by hand and the marshaling
functions by hand. Then anytime you change the type, you have to
marshal functions. There is also no guarantee that you did any of it
right with out testing.
4. Create a DSL for defining types which automatically generates the
limited set of types such that the types it generates are 'friendly'
it is likely to be restrictive enough that it is not especially nice
to use in either language. (Likely to be somewhat verbose I think...)
so that you only think in Haskell and don't have to think about
I'd like to hear about other options, or implementations of those
options that work well..
I have not tried using this algrebraic data type library for
On Jun 22, 2010, at 8:53 AM, Sergey Mironov wrote:
> Hi! This is definitely the right way. Current set of related
> technologies includes
> Formlets, HJScript, Web-routes, various template systems like Hamlet
> or HSX.
>> read Ajax responses and execute them in the web browser, for
>> the above functionality
>> listen for events and forward them to the server trough Ajax.
> Ajax is just one approach of several existing. Building a
> look at  and . what do you think?
> Generally, it is already possible to manage client java-scripts on the
> server with HSX + HJScript . On the other hand, managing pure html
> forms for JScript-free apps is possible with the help of Formlets. But
> when one starts using them all together, code becomes awkward.
>  http://www.haskell.org/haskellwiki/Haskell_in_web_browser
>  http://vir.mskhug.ru/
>  http://git.ierton.ru/?p=happstack-samples.git;a=blob_plain;f=HJSample.hs;hb=master
> web-devel mailing list
> web-devel at haskell.org
More information about the web-devel