local_assigns

The local_assigns method1 from ActionView::Base is a good way to figure out what local variables exist in a view.

Headline: <%= local_assigns[:headline] %>

same as

defined? headline && headline