aboutsummaryrefslogtreecommitdiffstats
path: root/actionmailer/lib/action_mailer/preview.rb
Commit message (Collapse)AuthorAgeFilesLines
* Make ActionMailer::Previews methods class methods.Abdelkader Boudih2014-08-141-0/+2
|
* Rename preview_enabled option to show_previewsRafael Mendonça França2014-07-011-4/+4
|
* Add configuration to enable mail previewsLeonard Garvey2014-07-011-0/+12
| | | | | | | | | | | | | | | | | | Adds `config.action_mailer.preview_enabled` This allows mail previewing to be enabled easily in non-development environments such as staging. The default is set to true for development so no changes should be required to existing Rails applications. The mail preview path can still be configured using the existing `config.action_mailer.preview_path` configuration option. Adding this avoids devs from having to do stuff like: https://gist.github.com/lengarvey/fa2c9bd6cdbeba96526a Update actionmailer/CHANGELOG with new configuration. Update configuring guide with new configuratation. Add `config.action_mailer.preview_path` to configuring guide.
* Fix typo [ci skip]Rafael Mendonça França2014-02-161-1/+1
|
* Don't use a class_attribute for ActionMailer::Base.preview_pathAndrew White2014-01-261-6/+2
| | | | | Since preview_path is read from ActionMailer::Base when previewing, subclasses can’t change it so don’t there's no need for the extra overhead imposed by using it.
* Add the ability to intercept emails before previewingAndrew White2014-01-261-2/+37
| | | | | | | | | | | | | | | | To support the ability for tools like CSS style inliners to operate on emails being previewed this commit adds a hook in a similar fashion to the existing delivery interceptor hook, e.g: class CSSInlineStyler def self.previewing_email(message) # inline CSS styles end end ActionMailer::Base.register_preview_interceptor CSSInlineStyler Fixes #13622.
* Add preview_path to autoload_paths in after_initializeAndrew White2014-01-041-1/+7
| | | | | | | | | | Only config.autoload_paths is frozen, so add the preview_path to ActiveSupport::Dependencies.autoload_paths directly in an after_initialize block. Also protect against a blank preview_path being added to autoload_paths which can cause a serious slowdown as Dir[] tries to load all *_preview.rb files under / Fixes #13372
* Add mailer previews feature based on mail_view gemAndrew White2013-12-171-0/+67