Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Building Modular Web Apps with Rack & Sinatra (web2media.net)
10 points by laktek on Dec 23, 2010 | hide | past | favorite | 3 comments


Interesting article, but I'm not sold on the benefits of N rack mini-apps vs a rails app w/ multiple controllers, the author even mentions that each mini-app is, in-essence, a controller. It honestly mostly just sounds like more of a pain in the ass.

I like sinatra, it's great for small apps, especially ones that do need to be embedded in other apps (resque-web, the resque control panel for example). However, I think a lot of people just end up making their own shitty version of Rails with it.


Actually, using n-rack mini-apps to replace, your Rails web app is not advisable. However, on cases where you need more fine grain control and customizing Rails can be a PITA, it's better to build the app from barebone Rack & Sinatra, using necessary middleware & libraries.

Though each mini-app looks like a controller, it beyond a controller because it's self contained.


"cases where you need more fine grain control and customizing Rails can be a PITA"

I'd love to see some examples where customizing Rails is a PITA and made easier by using Sinatra.

Personally I have little trouble making Rails do what I want, since I can get at the underlying Rack objects when I need to do things at the HTTP protocol level.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: