Support for custom object inside of .builder views

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Support for custom object inside of .builder views
My use case:

I have a project that uses the twilio-ruby gem's Tiwml library to generate XML. At the moment I put all of the syntax for generating the XML inside of the controller and render that manually. This seems off to me as the controller should be responsible for controlling small amounts of business logic and the view should be generating the XML. Is there a way to inject your own Ruby or builder object into .builder templates? If not, should this be a feature?

You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit