Web Dev Academy Backend frameworks · Ruby on Rails Tool 44 / 64
Backend frameworks

Ruby on Rails

The framework that defined "convention over configuration". Rails turns a few commands into a full CRUD app — model, migration, controller, views and routes — with the legendary rails generate scaffold.

Demo 01

rails generate scaffold Post

This single command is Rails' party trick. Type a model name and fields, click run, and watch the entire CRUD feature stream into existence.

rails g scaffold
    Demo 02

    RESTful routes Rails gives you

    One line — resources :posts — generates seven conventional routes. Here's the simulated rails routes output.

    # config/routes.rb
    Rails.application.routes.draw do
      resources :posts
    end
    → rails routes:
    VerbURI PatternController#Action
    GET/postsposts#index
    GET/posts/newposts#new
    POST/postsposts#create
    GET/posts/:idposts#show
    GET/posts/:id/editposts#edit
    PATCH/posts/:idposts#update
    DELETE/posts/:idposts#destroy
    Demo 03

    Active Record in the rails console

    Active Record is Rails' ORM. Run queries against a simulated posts table — and see the SQL it produces, just like the real rails console.

    Demo 04

    Controller action → response

    A controller action pulls data and renders. Click an action to "request" it through the simulated server.

    # app/controllers/posts_controller.rb
    class PostsController < ApplicationController
      def index
        @posts = Post.all
        render json: @posts
      end
    
      def show
        @post = Post.find(params[:id])
        render json: @post
      end
    end
    Demo 05

    The Rails doctrine

    Why Rails feels so fast to build with.

  • Convention over configuration — sensible defaults mean almost no boilerplate.
  • DRY — Active Record, generators and partials kill repetition.
  • Full-stack & integrated — ORM, routing, mailers, jobs, Hotwire — one cohesive package.
  • Built on Ruby — readable, expressive code that's a joy to write.
  • i
    The scaffold generator, rails routes table, Active Record console and controller responses are simulated with vanilla JavaScript — real Rails runs Ruby on a server (Puma) with a real database. The code blocks show genuine Ruby/Rails/Active Record syntax. The shared CSS shell provides page styling.

    ↑ All 64 tools