From the course: Ruby on Rails 6 Essential Training

Unlock the full course today

Join today to access over 22,400 courses taught by industry experts or purchase this course individually.

Using REST for resourceful routes in a Rails project

Using REST for resourceful routes in a Rails project - Ruby on Rails Tutorial

From the course: Ruby on Rails 6 Essential Training

Start my 1-month free trial

Using REST for resourceful routes in a Rails project

- [Instructor] In this movie, we're going to learn about a concept called REST and see how it leads us to resourceful routes. REST is short for representational state transfer. With REST, instead of performing procedures, we're going to be performing state transformations upon resources. Similar to what we saw in the last movie, this is about the way that we think about and structure our code. We talked about CRUD, we talked about organizing our code into resources. So for example, we have subjects and we have pages. Each one of those then can have actions performed on it. That's what this means by state transformations. You have your subjects resource, you can add a new subject to it, that's a transformation of its state. Or we can edit an item that's in the resource, again, another transformation of its state. So when we talk about REST, what we're really talking about is using CRUD to structure our code well, and…

Contents