title: what is the difference between redirect_to @article and article_path
body: <p>I am following this rails guides. And I have this following code</p>
  
  <pre><code>class ArticlesController &lt; ApplicationController
      def new
      end
  
      def show
          @article = Article.find(params[:id])
      end
      def create
          @article = Article.new(article_params)
          @article.save
  
          redirect_to @article
      end
  
  
      private 
  
          def article_params
              params.require(:article).permit(:title, :text)
          end
  end
  </code></pre>
  
  <p>In the above code, in the create action, I have modified @article to article_path. Which I believe is the same as per the routes. </p>
  
  <pre><code>Prefix Verb   URI Pattern                  Controller#Action
  welcome_index GET    /welcome/index(.:format)     welcome#index
           root GET    /                            welcome#index
       articles GET    /articles(.:format)          articles#index
                POST   /articles(.:format)          articles#create
    new_article GET    /articles/new(.:format)      articles#new
   edit_article GET    /articles/:id/edit(.:format) articles#edit
        article GET    /articles/:id(.:format)      articles#show
        # the above route
                PATCH  /articles/:id(.:format)      articles#update
                PUT    /articles/:id(.:format)      articles#update
                DELETE /articles/:id(.:format)      articles#destroy
  </code></pre>
  
  <p>So as per the routes, I mentioned the article_path. But when I did that, it redirects me to /articles instead of /articles/:id</p>
  
  <p>can anyone explain me what is happening. </p>