They are many options how to generate PDF versions of your invoices in Ruby and the ones that do not come with system dependencies are often built on top of Prawn library. InvoicePrinter is no different. Here is a short announcement on what it is (and aims to be) and what not.

I created InvoicePrinter to extract the mess of using Prawn directly in Rails views. The option of using plain Prawn was convenient, but once I started building some kind of view logic in views I stopped liking it. So I built this well-tested thin wrapper on top of Prawn to extract the code somewhere else. Actually last time I checked I am not the only one and there are other similar projects out there.

InvoicePrinter is different in two things. First, it does not impose on you anything. You don’t need to have I18n gem to do the translation of the labels. You don’t need to fight any kind of business logic of taxes for different tax system. It’s only a tested view layer, no other validations are part of it. And this is actually a feature. Second, it has its own unique standard design. I simply didn’t like the designs of others so I am offering an alternative. It might get some options to style borders or colors in future, but will most likely never support more layouts.