Taking Stimulus.js for a ride

Stimulus.js is one of the new front-end framework on the market. It’s goal is to be a modest JavaScript framework for the HTML you already have, which makes it ideal as an alternative to jQuery or framework-less JavaScript. Let’s see how it feels to replace VanillaJS with Stimulus.js on one concrete example. Continue reading

Do not run Rails with pending migrations

Database migrations are the tricky part of any deployment. They make zero-time deploys problematic. They requires special attention since they can break stuff. Some might choose to run migrations automatically, some of us run them manually. But one thing is almost always true; the production code without migrations should not ever run. So how not to run your code without doing migrations first?
Continue reading

Invoicing from the command line

Are you a freelancer? You don’t need to leave your command line to create invoices for your clients. InvoicePrinter is a Ruby library for producing PDF invoices without too much hassle. If you haven’t seen it before, you can read more about it in the announcement or its GitHub page. With the upcoming 1.1.0 release (currently as release candidate) a command line executable is included so you can now use command line to invoice your clients. No need to learn Ruby, just pass the data in the familiar JSON format! Here is how to create your first invoices. Continue reading