All,
I have come to a point where I would like to integrate some none-Radiant
managed views with Radiant views, and I'm trying to determine the best
overall approach.
I have some custom models which need to be represented in Radiant views,
and I would like to be able to take advantage of standard Rails
partials, Rails form helpers, (e.g. all the good things about ActionView).
I have a custom extension which holds all of my model information. I
have, in addition, created a Radius tag that is very close to rendering
a standard Rails partial using standard form helpers. I can't really
see the point in using the forms extension when the field helper tags in
it provide less functionality than standard Rails helpers (and there is
no support for textarea <input> elements).
Generally speaking, it seems that there are 3 options:
1) Do not use Rails partials at all, enhance the existing forms
extension to provide more ActionView helper-like functionality.
Basically, stay within the limits of Radiant.
2) Continue down the path I'm on, which is basically wrapping a Rails
partial with a Radiant tag (similar to this post from the Radiant list:
http://www.ruby-forum.com/topic/133878)
3) Figure out a way to hook into the Site controller and merge content
generated via both standard Rails mechanisms and Radiant (I know how to
hack around double render issues, etc.). I'm thinking that the
SiteController could basically become a mini-dispatcher when necessary
to run standard Rails actions, and ultimately render standard Rails
views/helpers, which can then be inserted into the HTTP response.
Thoughtful responses appreciated.
Many thanks,
Wes