123456789_123456789_123456789_123456789_123456789_

Module: ActionMailer::Previews

Do not use. This module is for internal use only.
Relationships & Source Files
Namespace Children
Modules:
Extension / Inclusion / Inheritance Descendants
Included In:
Super Chains via Extension / Inclusion / Inheritance
Class Chain:
Defined in: actionmailer/lib/action_mailer/preview.rb

Class Method Summary

::ActiveSupport::Concern - Extended

class_methods

Define class methods from given block.

included

Evaluate given block in context of base class, so that you can write class macros here.

prepended

Evaluate given block in context of base class, so that you can write class macros here.

append_features, prepend_features

Instance Method Summary

DSL Calls

included

[ GitHub ]


9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# File 'actionmailer/lib/action_mailer/preview.rb', line 9

included do
  # Add the location of mailer previews through app configuration:
  #
  #     config.action_mailer.preview_paths << "#{Rails.root}/lib/mailer_previews"
  #
  mattr_accessor :preview_paths, instance_writer: false, default: []

  # Enable or disable mailer previews through app configuration:
  #
  #     config.action_mailer.show_previews = true
  #
  # Defaults to true for development environment
  #
  mattr_accessor :show_previews, instance_writer: false

  # :nodoc:
  mattr_accessor :preview_interceptors, instance_writer: false, default: [ActionMailer::InlinePreviewInterceptor]
end

Instance Method Details

#preview_path

[ GitHub ]

  
# File 'actionmailer/lib/action_mailer/preview.rb', line 28

def preview_path
  ActionMailer.deprecator.warn(<<-MSG.squish)
    Using preview_path option is deprecated and will be removed in Rails 7.2.
    Please use preview_paths instead.
  MSG
  self.class.preview_paths.first
end