Rails will now have a default authentication generator out of the box!
In the previous episode we ran the generator, allowing existing users to sign in.
Now let's add a registrations
feature, that will enable sign ups (creation of new users).
I hope this feature gets merged into Rails too!
Yet, to make this authentication solution viable in production, you will still need to add AT LEAST password reset
and email confirmation
functionality.
I highly recommend to use Devise for authentication, rather than reinvent the wheel.
Episode source code: https://github.com/corsego/178-rails-8-authentication-generator/commit/b94b002dc7c4c685fb86956cab1fc3e3d9233473
Based on this blogpost: https://blog.corsego.com/rails-8-authentication-registration