Rails Routes

 Rails Routes


       01

How can we give the root route:

           

          root 'sharks#index'


      Route this:

      /pages/show/1

           root :to => "pages#show", :id => '1'                   :::::::::::::::::::::::::::::  {It may work}

              root 'blogs#show', {id: 1}                                   :::::::::::::::::::::::::::::  {It may work}

         

    

Comments

Popular posts from this blog

Rails 7 Features :: Comparison with Rails 6 and Rails 5