purify / mail_style

Making HTML emails a little less painful. Writes css inline and corrects image urls.
http://blog.purifyapp.com/2009/12/30/mailstyle-a-html-email-plugin-for-ruby-on-rails/
MIT License
192 stars 39 forks source link

Public API #5

Open recruitmilitary opened 14 years ago

recruitmilitary commented 14 years ago

It would be really awesome if you could do something like this:

css_path = "/path/to/stylesheet.css"
html_path = "/path/to/page.html"

# return html document with styles inline
MailStyle.inline_styles(html_path, css_path)

This would allow MailStyle to work outside of Rails/ActionMailer.

Thoughts?

asoules commented 14 years ago

This would also allow me to remove my Heroku patch that points the CSS to RAILS_ROOT/tmp/sass-output