July 28, 2020

Let's build for Ruby and Rails developers - Part 3

Configuration and Initial App Setup

Welcome back to part 3 of my series titled "Let's build for Ruby on Rails developers" where I'll begin creating a new Ruby on Rails app and configuring it for the development journey ahead.

If you landed on this page and haven't seen the previous parts I recommend watching those first to get a lay of the land!

The series so far

Continuing in part 3

In this part, I'll be creating a new Ruby on Rails application which will be the framework of choice for this build. I'll also be leveraging an application template I made called kickoff_tailwind which is a huge time saver when it comes to creating and configuring a new Ruby on Rails application.

If you're following along I recommend cloning the template and using it along the journey. Bundled with it is Tailwind CSS and a few gems I swear by including Devise, Sidekiq, FriendlyId, and name_of_person. These all get installed and configured by default for the most part.

I'll continue installing a few gems I like to leverage during development including Faker, Annotate, inline_svg, and Pay. We'll need Stripe, Stripe Event, and a handful of other gems as well.

Thinking about tests

Rails ships with minitest and Capybara by default so I think it makes sense to leverage that framework as well as the fixture pattern. I realize Rspec is a more popular solution but I prefer to keep things light and configuration as simple as possible. An application like this is going to be iterated on overtime so I think the mindset of knowing things can change at any moment is a healthy one to have.

Databases

The default database type on vanilla rails apps are sqlite3 based. This is suitable for development but I'll be opting for PostgreSQL because our production app will live on such a database. You're welcome to use whatever type of database you wish if you're following along. Just know services like Heroku enforce PostgreSQL(I'll be using hatchbox.io).

Git flow

For each part of this series, I'll be creating a fresh branch so you can have reference points along the way. This is great for both adopting a good Git flow and so there are obvious historical checkpoints we could always revert back to if necessary. You can find the repo here or linked in the sidebar to the right.

The main repo for this project is found at https://github.com/justalever/railsdevs_public

Leave a reply

Sign in or Sign up to leave a response.

0 responses

Est. reading time: 3 minutes
Stats: 271 views

Categories

Collection

Part of the Let's Build for Ruby and Rails Developers collection