-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add devise #5
Add devise #5
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Sazzad,
You did extremely great on this project! 👏 👏
There are however a few issues that you still need to work on to go to the next project but you are almost there!
🏁 🚦 ⛪ 🚜 🏃 🌴 🏫 🌳 🏘️
Highlights 👍
- Authentication is coming up well so far, good job!
- ReadMe looks great!
Required Changes ♻️
Kindly check the inline comments under the review.
Cheers and Happy coding!👏 💻 🍷
Feel free to leave any questions or comments in the PR thread if something is not 100% clear.
Remember to tag me in your question so I can receive the notification.
Please, do not open a new Pull Request for re-reviews. You should use the same Pull Request submitted for the first review, either valid or invalid unless it is requested otherwise.
As described in the Code reviews limits policy you have a limited number of reviews per project (check the exact number in your Dashboard). If you think the code review was unfair, you can request a second opinion using this form.
|
||
<%= form_for(resource, as: resource_name, url: session_path(resource_name)) do |f| %> | ||
<div class="field"> | ||
<%= f.label :email %><br /> | ||
<%= f.email_field :email, autofocus: true, autocomplete: "email" %> | ||
</div> | ||
|
||
<div class="field"> | ||
<%= f.label :password %><br /> | ||
<%= f.password_field :password, autocomplete: "current-password" %> | ||
</div> | ||
|
||
<% if devise_mapping.rememberable? %> | ||
<div class="field"> | ||
<%= f.check_box :remember_me %> | ||
<%= f.label :remember_me %> | ||
</div> | ||
<% end %> | ||
|
||
<div class="actions"> | ||
<%= f.submit "Log in" %> | ||
</div> | ||
<% end %> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- This activity requires the modification of the views in devise for the registration and login to match the styling of the provided wireframe(s). Kindly ensure that the form (inputs and buttons) stretches across the screen and is centered accordingly for both Login and Signup pages, as seen in the wireframe:
Your Signup view: | Your login view: | Wireframe login view (Required): |
---|---|---|
app/models/user.rb
Outdated
# Include default devise modules. Others available are: | ||
# :confirmable, :lockable, :timeoutable, :trackable and :omniauthable | ||
devise :database_authenticatable, :registerable, | ||
:recoverable, :rememberable, :validatable |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- As part of this activity's requirements, we want a user to be asked for confirmation of email during the registration process, therefore let's ensure to enable the
:confirmable
option.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @SAZZAD1Q2 and @Theodoraldo
Your project is complete! There is nothing else to say other than... it's time to merge it
Congratulations! 🎉
Highlights
:confirmable
is enabled in user model ✅
Optional suggestions
Every comment with the [OPTIONAL] prefix is not crucial enough to stop the approval of this PR. However, I strongly recommend you to take them into account as they can make your code better.
You can also consider:
- N/A
Cheers and Happy coding!👏👏👏
Feel free to leave any questions or comments in the PR thread if something is not 100% clear.
Please, remember to tag me in your question so I can receive the notification @prolajumokeoni.
As described in the Code reviews limits policy you have a limited number of reviews per project (check the exact number in your Dashboard). If you think that the code review was not fair, you can request a second opinion using this form.
In this PR, I integrated devise for authentication in the project
Project requirements
current_user
method inApplicationController
, devise will provide us with one.