[Haskell-cafe] Is it possible to "easily" connect Haskell to
golubovsky at gmail.com
Thu Oct 21 09:16:20 EDT 2010
Atze Dijkstra wrote:
>but to provide a proper interface to XML/HTML DOM (see http://www.haskell.org/haskellwiki/Haskell_in_web_browser), or a GUI abstraction around it (perhaps a subset of wxHaskell?)
>will take more work & time. I hope this can be done as part of a studentproject, or maybe picked up during a Hackathon.
I think a big portion of this task might be done using this package:
or its newer (not published on Hackage, but recommended) version split
into two (you need both):
http://code.haskell.org/yc2js/webidl/ -- lexer (FFI based),
parser, and a test program.*
http://code.haskell.org/yc2js/webidlsyn/ -- just AST and pretty-printer
I must admit: I haven't touched this project for more than a year, and
have little plans to do so: it is up for grabs by anyone interested.
But if it can parse something like this:
it's likely still intact. Back in those days it could.
A WebIDL converter helps derive type signatures for DOM methods and
attributes (just like HSFFIG does this for C function prototypes).
Have fun ;) and don't hesitate to ask questions.
PS I'm glad that the idea lives on. With more GHC flrxibility on
in browsers, this can get a second life...
* the whole repo has to be downloaded: darcs get http://code.haskell.org/yc2js/
Anywhere on the Web
More information about the Haskell-Cafe