method

decorate_attributes

rails latest stable - Class: ActiveModel::AttributeRegistration::ClassMethods

Method not available on this version

This method is only available on newer versions. The first available version (v7.2.3) is shown here.

decorate_attributes(names = nil, &decorator)
public

No documentation available.

# File activemodel/lib/active_model/attribute_registration.rb, line 23
      def decorate_attributes(names = nil, &decorator) # :nodoc:
        names = names&.map { |name| resolve_attribute_name(name) }

        pending_attribute_modifications << PendingDecorator.new(names, decorator)

        reset_default_attributes
      end