I have a rails 5.2 app with the following in config/routes.rb
root to: 'home#index'
Upon running rails s, I get the following error :
undefined method `to' for #
Did you try using the shortcut?
root 'home#index'
And did you already use get to map the request?
get 'home/index'
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.