Created
February 6, 2011 03:30
-
-
Save samleb/813088 to your computer and use it in GitHub Desktop.
Use ActionView 3 outside of request/response cycle
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class View < ActionView::Base | |
| include Your::Application.routes.url_helpers | |
| include ApplicationController._helpers | |
| delegate :config, :to => ActionController::Base | |
| end | |
| # For some reason `render :partial => 'foo/bar'` doesn't work... | |
| View.new.render :file => 'app/views/foo/_bar.html.haml' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment