I can confirm that when I run rails generate devise:views and look at the default working template copied from the gem, in the application /views/dev/regations/new.html.erb, form_for is called by Devise with arguments:
form_for(resource, :as => resource_name, :url => registration_path(resource_name)) do |f|
If you prefer a link to copy gem views, view the views in the repo .
However, if you (or someone else reading this) try to use the registration form with your own controller, it is quite possible that you will need to recreate some of the methods from the Devise controller in order to get the form for rendering . Assuming you called your user class User :
def resource_name :user end def resource @resource ||= User.new end def devise_mapping @devise_mapping ||= Devise.mappings[:user] end
source share