Photo by Joanna Kosinska on Unsplash

So you want to unlock the full potential of a Rails website? Do you want to take it from your simple localhost environment to the real world? If you are doing this, then congratulations are in order because you are about to have a lot more fun with Rails.

In a real-world website, it is common to have the capability to send an email for welcoming purposes, authentication purposes, or regular newsletters. Let’s talk about how we can utilize Action Mailer to accomplish this.

The Objective

A couple of months ago, I made a mock website of a company I was interested…


Photo by Mathieu Stern on Unsplash

Next.js has several methods to provide authentication. Being that it is one of the main players in the JAMstack game, it can do this without a traditional backend as well. But if are coming with your own backend, be it in Express, Django, or in this example Rails, Next.js can handle that too. JSON Web Tokens are a viable and secure option.

What is JSON Web Tokens?

A JSON Web Token is an encoded Token that can be sent over the Web with JSON. More specifically it is an encoded string that contains data that can be decoded to reveal this data. For example, when…


Photo by Markus Winkler on Unsplash

So you want to convert your SQLite database in Rails to Postgre? That is why you are here right? Let’s get started. 😊

Check Postgre Version

First, you have to check if you have Postgre via the command line. If you have Ubuntu then Postgre should come installed by default.

psql -V

If nothing comes up then you will have to install Postgre.

For New Projects

If you are creating a new Rails project, you can specify on creating that you will opt-out of the standard SQLite setup in favor of Postgre.

rails new my_app --database=postgresql

This should take care of all your woes. …


Photo by bruce mars on Unsplash

Well, I have been loving all of the speed of Next.js, one of the hottest tools out right now for React developers. Next.js 10, which was released just in October 2020 has some impressive image optimization features. The Next.js Image Component is able to preload various image sizes to best fit small viewports, rather than loading a 2000 x 2000 size image on a small iPhone. This has led to improvements to the Largest Contentful Paint(LCP) of websites. The Image Component will also automatically convert images to faster lighter formats on demand! Look up .webp images for more information. Next.js…


Photo by Kenneth Schipper Vera on Unsplash

Haml has nothing to do with pork, ham, or any of the three little piggies and the big bad wolf, but you knew that right? Haml stands for HTML Abstraction Markup Language. It is a powerful tool that replaces standard ERB and should be in every Ruby Developer’s toolchain because it can get rid of those big bad wolves. Let consider how…

1. Speeds Up Development

That’s right! We are talking about speed. Chances are if you are using Ruby on Rails you know it is about “convention over configuration”. A lot of the design choices are already made for you. …


Photo by Sebastian Herrmann on Unsplash

In the process of being a one-man developer show, don’t we find that the time we spend actually coding is only part of the process? You have to come up with a decent design, code the “thing”, and then do some DevOps when you deploy the said, “thing”. Sometimes we can get stuck down the rabbit hole of researching how to accomplish these tasks.

In this article, we will talk about how to add an SSL to your Rails API endpoint when it is hosted on Heroku.

Why Add An SSL?

As mentioned in part 1 of this series, if you using a Rails…


Photo by Maxwell Nelson on Unsplash

In a previous article, I broke down how one would use the Faraday Gem to make calls to a third-party API from your Rails application when it is in the development stages. If you deploy your application to Heroku then you will need to implement certain solutions to make sure your API calls function properly. In this article, I will show you how I approached this challenge.

What is the problem?

As many may know, an app that is running well in your local environment is not guaranteed to run at all in a real-world production setting.

Now let say you have a frontend…


Photo by Joshua Fuller on Unsplash

Working with APIs is a daily occurrence for developers. Most resources on the internet show how to retrieve this information with Javascript on the front end, I wanted to demonstrate how this can be done on the server-side with Ruby. But you may ask, why do fetch calls on the server-side?

This is a valid question. The answer has to do with making your application more secure. When API keys, client secrets, or client ids are stored in the front end of a web app, they can be more easily discovered through clever manipulation with the browser’s dev tools.

Faraday Gem Setup

You…


Photo by Toa Heftiba on Unsplash

Programming can be tough. App development can be even tougher. There is so much to think about. The planning stage, the actual making it work stage, and finally refactoring. Thanks to Rails MVC and separation of concerns, it makes it so much easier to keep your code readable for the next developer and even yourself down the road. What I want to highlight in this post is, drumroll, view helper methods!

In case you don’t know what I am talking about, helper methods “help” abstract the Ruby logic out of your view (kind of a pun). …


Photo by REVOLT on Unsplash

After a dedicated 4 weeks of an eat, sleep, and code routine here at this amazing Flatiron program, I arrived at a milestone, my first CLI project. Henceforth, the birth of the Sneaker Finder Ruby Gem. I want to take some time to document my findings. I also want to share the key take away points in my learning journey thus far. I believe this gem summarizes it well. Let’s begin…

What does it do?

The purpose of this gem is to scrape the inventory from a well-known e-commerce store that has a collection of rare, hard-to-find sneakers that collectors are looking for.

How do we use it?

I…

Uriah Harston

Full-Stack Software Engineer and Lifelong Learner

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store