Recall & Review
beginner
What is the first step to install Ruby on Rails?
Install Ruby on your computer first because Rails is a Ruby framework. You can download Ruby from the official website or use a version manager like rbenv or RVM.
Click to reveal answer
beginner
How do you install Rails after Ruby is installed?
Use the command
gem install rails in your terminal. This downloads and installs the Rails framework on your system.Click to reveal answer
beginner
What command creates a new Rails project?
Use
rails new project_name. This sets up a new folder with all the files and folders Rails needs to start your app.Click to reveal answer
intermediate
Why do you run
bundle install after creating a new Rails app?It installs all the Ruby gems (libraries) your app needs, as listed in the Gemfile. This makes sure your app has all the tools it requires.
Click to reveal answer
beginner
How do you start the Rails server to see your app in a browser?
Run
rails server or rails s in your project folder. Then open http://localhost:3000 in your browser to see your app running.Click to reveal answer
Which command installs the Rails framework?
✗ Incorrect
The command
gem install rails installs the Rails framework after Ruby is installed.What does
rails new myapp do?✗ Incorrect
The command
rails new myapp creates a new Rails project folder called myapp with all necessary files.Why is Ruby needed before installing Rails?
✗ Incorrect
Rails is built with Ruby, so Ruby must be installed first for Rails to work.
What is the purpose of
bundle install?✗ Incorrect
bundle install installs all the Ruby libraries your app needs as specified in the Gemfile.After running
rails server, where do you go to see your app?✗ Incorrect
The Rails server runs on port 3000 by default, so you visit
http://localhost:3000 to see your app.Explain the steps to install and set up a new Rails application from scratch.
Think about what you need before Rails, how to get Rails, and how to start your app.
You got /5 concepts.
Describe what happens when you run the command 'rails new project_name'.
Imagine setting up a new workspace for your app.
You got /4 concepts.