
Snap for Beginners: Haskell Web Development - biscarch
http://snapforbeginners.com/
======
BadassFractal
Anybody know of solid super-entry level tutorials for starting Web Development
with Haskell with less opinionated libraries like Scotty? Something that shows
you how to slap together a solid cabal sandboxed ready-to-deploy application
that's a mix of Scotty/Persistant/Esqueleto and all the other basics?

Clojure has "Web Development with Clojure" which is basically what I listed
above, except for Clojure rather than Haskell.

~~~
boothead
I gave a talk at a Haskell meetup in London this week that covered some of
this - the slides won't really be useful standalone, but I could probably re
purpose them to a blog post fairly easily if you're interested?

~~~
pdpi
Not sure about the OP, but I'd definitely love to read that.

~~~
prawks
Ditto

------
boothead
Currently heading up a team of awesomely smart people building our back end in
Haskell on snap. AMA!

~~~
nnutter
How do you plan to deploy your backend? Are there tools to do it? Is it just
rsyncing a cabal sandbox to another machine? What about compiling and stuff?
(I've barely made my way through LYHGG.)

~~~
begriffs
You can deploy Snap apps to Heroku pretty easily.

[https://github.com/begriffs/heroku-buildpack-
ghc](https://github.com/begriffs/heroku-buildpack-ghc)

------
kayloos
There's a new web library that extends Scotty with basic session and
authenticiation support, called Spock.

I used it for a personal project of mine, which is creating an rss reader
resembling the now dead iGoogle (which I loved), and although I had to read a
lot of source code to get it to work, I really enjoyed how I worked with it,
after figuring out the patterns on how to use it.

It definitely isn't finished, it could use some love by some eager developers,
but in my opinion it has the potential to be the best framework out there.

\- It extends scotty, so defining routes and control logic is fast and simple
\- It does not cage you in with a template language, or libraries that you
don't want thrown in your face.

For example, I used Scotty with my own templating language I made for fun
(hemplate), as well as a validation library I made, which I hope to finish in
the near future, (after I get a job).

[http://hackage.haskell.org/package/Spock](http://hackage.haskell.org/package/Spock)

------
MaxGabriel
Cool, this is really good for Snap. I heard good things about Snap, but a
major reason I went to Yesod instead was that it had a book that I could work
through (For a Haskell beginner like me, having some structure was important).

~~~
codygman
I was about to use Yesod instead also, then I came across OP's book.

------
egonschiele
Finally! Snap is a great framework but it's been missing a good guide for a
while.

------
cgag
I just started playing with Scotty while I learn, but I'm beginning working on
a web app in Haskell and was leaning towards using Snap. I'll almost certainly
pick this up. That new IO manager is a beautiful thing.

------
rgbrgb
Please consider changing the title font. It is very hard on my eyes.

~~~
andrewflnr
As long as we're talking about the appearance, I had to zoom out to be able to
see the text with Firefox 27, and then stuff started moving around like some
pieces of it were centered with different methods or something.

------
sssilver
The typography makes my eyes bleed.

~~~
houzi
Did you have problems with extremely ugly typefaces in the sample chapter? I
had horrible typefaces with bold ligatures. It seemed as if my hinting and
sub-pixel rendering had stopped working. There were many errors and warnings
in the debugging console as well.

------
maxharris
How does this compare with Meteor? I love Haskell, and if Snap can do the same
kind of magic that Meteor does, I'll switch.

~~~
codygman
Meteor is more for front-end right? I think Snap is mostly for the backend
portion of that, however there are some Haskell to Javascript libraries which
may enable functionality you get with Meteor (as well as the type safety most
know and love).

~~~
kazagistar
Meteor is for both ends at the same time. Most of your code on front end and
back end is shared, including database queries, in a safe way.

------
acconrad
Is there a site analogous to the Rails Tutorial e-book, but for Haskell?

------
sudeep1
why anyone would want to build with snap leaving RoR behind.

~~~
copergi
Yes, leaving RoR behind is certainly one reason for some people to use snap.
But even for people who didn't fall into the rails trap, haskell is much nicer
for web development than most languages (PHP, python, java, C#, etc).

