RubyonRails

What I Can Do In 10 Minutes - With Ruby on Rails

A live coding demonstration showing the rapid development capabilities of Ruby on Rails by building a functional blog application with user authentication and URL slugs in just 10 minutes.

Published Aug 21, 2025 by Malachi Rails

Key Insights

  • Ruby on Rails allows for incredibly rapid application development, with a functional blog created in under 10 minutes

  • Scaffolding in Rails automatically generates CRUD operations, saving significant development time

  • Adding user authentication with Devise requires minimal code and configuration

  • Tailwind CSS can be quickly integrated for styling Rails applications

  • URL slugs can be implemented easily using the Friendly ID gem to create more readable URLs

  • Rails conventions and gems drastically reduce the amount of code needed to implement common features

0:00

Project Setup and Scaffold Creation

“I'm going to create a new application called Rails new my app. And then we're going to say CSS is equal to Tailwind.”

The video begins with the presenter creating a new Rails application with Tailwind CSS integration. After setting up the initial project structure, they generate a scaffold for a 'Post' model with title and body attributes. This demonstrates the rapid development capabilities of Rails, as the scaffold automatically creates all necessary files for CRUD (Create, Read, Update, Delete) operations.

The presenter encounters a minor issue with Tailwind CSS not applying correctly and quickly resolves it by adding the Tailwind CSS CDN to the application layout. They also add some basic styling with padding to improve the appearance of the application.

Takeaways

  • Rails scaffold command generates a complete set of model, view, and controller files in seconds

  • Rails can be initialized with CSS framework preferences (Tailwind in this case)

  • Quick troubleshooting of CSS issues demonstrates the flexibility of the framework

  • Basic CRUD functionality can be implemented without writing custom code

1:30

Adding User Authentication with Devise

“The next thing that we're going to do is add device. So we have to add a user account to actually make this work.”

The presenter adds user authentication to the application using the Devise gem. With just a few commands, they install Devise, generate a user model, and run migrations to set up the database schema for authentication. This demonstrates how Rails' ecosystem of gems can dramatically speed up the implementation of common features.

After implementing authentication, they modify the Posts controller to require authentication for creating, editing, and deleting posts while keeping the index and show actions public. They also set up the application's root route to point to the posts index page and add sign-in and sign-out functionality to the layout.

Takeaways

  • Devise gem provides complete authentication solution with minimal configuration

  • Authentication restrictions can be applied selectively to controller actions

  • Rails' before_action filters make security implementation straightforward

  • Flash messages for notifications (alerts and notices) can be easily integrated

4:17

Implementing URL Slugs with Friendly ID

“Next thing we're going to do is just go to rubygeems.org and we're going to add a gem called friendly ID.”

In the final segment, the presenter enhances the application by implementing URL slugs using the Friendly ID gem. This improves the application by creating more readable URLs based on the post titles instead of using numeric IDs. They add the gem, create a migration to add a slug field to the posts table, and configure the Post model to use Friendly ID.

After implementing the changes, they demonstrate how the URLs now show the post title instead of the ID. They also modify the Post controller's set_post method to use friendly.find instead of the standard find method to ensure that posts can be found by their slugs.

Takeaways

  • Friendly ID gem simplifies the implementation of SEO-friendly URLs

  • Adding database migrations in Rails is straightforward with built-in generators

  • Model configuration requires minimal code to implement slugs

  • The implementation demonstrates Rails' principle of convention over configuration

Conclusion

This demonstration showcases the remarkable efficiency of Ruby on Rails for rapid application development. In just 10 minutes, the presenter built a functional blog application with user authentication, CRUD operations, and SEO-friendly URLs—tasks that would typically take hours in many other frameworks.

The power of Rails lies in its conventions, robust ecosystem of gems, and emphasis on developer productivity. By leveraging Rails' scaffolding, the Devise gem for authentication, and Friendly ID for URL slugs, developers can focus on building unique features rather than reimplementing common functionality.

So what? For developers and businesses looking to quickly validate ideas or build MVPs, Ruby on Rails remains one of the most productive frameworks available. This video demonstrates that with Rails, you can go from concept to functional application in minutes rather than days, allowing for faster iteration and feedback cycles in the development process.