RdBlog::Engine.routes.draw do
  get '/atom.xml' => 'posts#feed', as: :feed, format: 'xml'

  resources :subscribers
  resources :posts, path: "", param: :slug, except: [:new, :create]
  post '/posts' => 'posts#create', as: :create_post
  get '/posts/new' => 'posts#new', as: :new_post
  get '/posts/drafts' => 'posts#drafts', as: :drafts

  root to: 'posts#index'
end
