Please read for an updated status on RailsCasts:
Learn more or hide this
Does this make performance faster than erb or its all about how to make your own template? nice screen cast.
Ryan, you can use <<-RUBY instead to get highlighted heredoc in Textmate.
thanks for the tip! Also works nicely in Sublime Text 2
Thank you for doing RailsCasts and offering a pro subscription reasonably. May I ask if you could make a video about code formatting within either a template or on a page. Like the way GitHub or GitGist formats code?
Or the way you're doing it on your own site!
Do you mean like he does in #207? There is even a revised one.
Ryan, your approach with truly nested templates for JSON nicely circumvents some problems I've encountered with RABL.
This can also be used to extract a JSON paginator into a template which can then be used across different models.
Thank you, Ryan for this awesome Railscast!
Everything was great up till the end when you did that markdown erb hack.
I agree about tilt, it would make things much easier.
Ryan, in rails master .rb was renamed to .ruby:
register_template_handle accepts a glob of extensions, so instead of registering each template extension like:
you can do:
ActionView::Template.register_template_handler(:md, :markdown, MarkdownTemplateHandler)
This is perfect. I needed to export some data as CSV, and all the previous go-by's I had seen built the CSV content in the controller. Yucky! This moves it out to the view template where it should be, and frees you up to make the respond_to handler look nice and pretty. Good work!
Ryan, there is one hidden bug in this episode.
You won't see any difference unless you try writing partials in Markdown. I'm on Rails 3.2.12.
thanks for posting such good examples you portray everything so simply thanks for posts buddy helps a lot https://goo.gl/VmqZjF
First sign in through GitHub to post a comment.