Comments Structure
Set up your comments model.
We'll cover the following...
We'll cover the following...
The next step for your app is to handle user comments. For this, you will need to set up a Comment
model similar to what you did for Link
.
You will run the following to generate the scaffolding for your Comment
model.
rails g scaffold Comment body:text link_id:integer:index user:references
Running this command will generate a migration file ...