Basic Challenge: Configure Views

Modify your views by adding control flow statements.

We'll cover the following

Problem statement

With your User model set up, you need to make some changes to your views and actions to serve up different things based on whether the user is currently signed-in or not.

You are required to make changes to the app/views/layouts/application.html.erb file to do the following:

If the user is signed-in:

  1. Display a link to Edit Account, which will allow the user to make changes to their account.
  2. Display a link to Sign-out, which will end the current user’s session.

If the user is signed-out:

  1. Display link to Sign-up, which will take the user to the new user registration form
  2. Display a link to Sign-in, which will take the user to the new user session form.

Get hands-on with 1200+ tech skills courses.