Ruby on Rails Friday, March 24, 2017

Hi there!

In my project I have a few engines. Each engine has its own set of Mailers and templates.

I want to have Previews for each specific engine, and keep them in engines.

I've found that ActionMailer Preview provides a way to change a path to preview classes, but looks like it's impossible to use an array of paths, or use something like `prepand_view_path / append_view_path ` like we can do in controllers.

https://github.com/rails/rails/blob/3faf7485623da55215d6d7f3dcb2eed92c59c699/actionmailer/lib/action_mailer/preview.rb#L92

Is there any way to have multiple paths for ActionMailer Preview?

Is it possible to create some kind of monkey patch to implement it?

Thanks!

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/b41624e5-ff1c-47b2-b6aa-931e8a931081%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment