TodoApp on Seaside in 218 lines
I have been a fan of Seaside since 2006. I am getting better at navigating and understanding how it works internally, and I have a Technorati search on Seaside in my newsreader to keep up to date on Seaside news.
After reading Ramon Leon’s A Simple File Based Wiki in Seaside, I wanted to implement another Rails first-time application, but on Seaside this time: the Todo list. To make things more interesting, I decided I would also make it multi-user.
Please note I am in no way an expert on how to do authentication in Seaside. But I took this as an opportunity to play with decorators, which I did not have the opportunity to do previously.
As Ramon did, I will assume you have a working knowledge of Squeak, Smalltalk and Seaside. Unlike Ramon though, I will guide you through the whole thing: models, controllers and views. Sorry, no tests this time around.
Where appropriate, I will contrast Smalltalk vs Ruby, my usual day-time language of choice.
UPDATE: 2007-10-15: Ramon Leon kindly took the time to review the code and gave me a few pointers. The original article documented revision 3, implemented on Seaside 2.7. This is now Seaside 2.7, and I updated the code to include Ramon’s suggestions.
UPDATE: 2007-10-15: The Monticello package is now up to revision 5, after more suggestions from Ramon.
If you want the goods immediately, setup a Monticello repository on http://mirror.teksol.info/monticello/todo and get the Todo package. You need a Squeak image with Seaside pre-installed. I suggest either Ramon Leon’s My squeak image or Damien Cassou’s Squeak’s developer images. On my Ubuntu Linux, I used Damien’s with the Squeak Debian package.
Read the rest of this entry