- Clone (
git clone
) this app to your local drive cd
intofill_in_the_blanks
and runbundle
- Oh no! One of your gems has gone rogue! Find it and remove it. While you're there, add the
pry-rails
gem to your app. Which group block does this gem go inside? - Run
bundle
again - Run
rails server
- Navigate to
localhost:3000
in your browser. What does the error indicate? - Run the proper command to resolve the error.
- Run
rails server
again, islocalhost:3000
working? Read the new error then continue on to step 9... - There's a controller already made for you (not application_controller), navigate to that controller and inspect the name, what's wrong with it? (Think convention) Find the problem and correct it.
- Navigate to your routes and fix the code there to resolve the error from your browser (Hint: It has to do with your
root
). - Your controller has all of your CRUD actions and a private method for whitelisting, but they're empty. We'll fill them out as we move through the following steps, use the comments inside of the actions as guidelines.
- Create corresponding views for each of your actions.
- Which actions do we not create views for? Why?
- Navigate to
localhost:3000/posts/new
in your browser - Oh no, we get an error! What does the error indicate? How can we fix it?
- Create routes for your posts. Does the error go away?
- We have some seeded data already in the app, where is it located? What command do we run to seed the data?
- Run the seed command in your terminal.
- Now we have some seed data, how can we get that data to display on our index view?
- Fill in the code to have our posts display properly.
- We want to add some more posts, edit your
new
view and the corresponding_form
partial to allow creation of new posts via a form. - What other files do we need to fill in before the new form will work properly? Be sure to add validations to the Post model.
- Go back to your posts_controller and fill in the corresponding actions to allow creation and viewing of a Post.
- Now we want to go back and edit one of our existing posts. Fill in the corresponding view and actions to make this work.
- Almost done! Add a button next to each Post that allows us to destroy that post.
- Edit your layout to have a custom, site wide, title (i.e., "Ian's Rails App!")
- Add links for easy navigation between pages
- Be error free
- Have your index page display all of your posts
- Including the seeded data that came with the app
- Allow your to Create, Read, Update, and Destroy posts
- Have your root set to your posts index
Push this app to a new repo in your GitHub called fill_in_the_blanks
then submit the link via Piazza# posts_app