instance method helper_attr

Ruby on Rails 2.2.3

Since v2.2.3 Last seen in v2.3.18

Available in: v2.2.3 v2.3.18

Signature

helper_attr(*attrs)

Declare a controller attribute as a helper. For example,

helper_attr :name
attr_accessor :name

makes the name and name= controller methods available in the view. The is a convenience wrapper for helper_method.

Parameters

attrs rest
Source
# File actionmailer/lib/action_mailer/helpers.rb, line 86
      def helper_attr(*attrs)
        attrs.flatten.each { |attr| helper_method(attr, "#{attr}=") }
      end

Defined in actionmailer/lib/action_mailer/helpers.rb line 86 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActionMailer::Helpers::ClassMethods

Type at least 2 characters to search.

↑↓ navigate · open · esc close