> So let's think about how we can fix scaffolding in
> a way that it doesn't require the database to exist before running.

My first proposal for how to fix this is simply to have
script/generate scaffold return to doing <%= form(@product) %> instead
of writing out the individual lines. Yes, it is kinda neat to have
that, but the pain is not worth it.

This affects page 98 of the book, but that should probably be
rewritten using form_for instead anyway.

And it also doesn't break any existing applications. It's just a new
behavior for new runs of that generator.
--
David Heinemeier Hansson
http://www.loudthinking.com -- Broadcasting Brain
http://www.basecamphq.com   -- Online project management
http://www.backpackit.com   -- Personal information manager
http://www.rubyonrails.com  -- Web-application framework
_______________________________________________
Rails-core mailing list
Rails-core@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-core

Reply via email to