modular_routes icon indicating copy to clipboard operation
modular_routes copied to clipboard

Pass api mode through options

Open vitoravelino opened this issue 3 years ago • 0 comments

Sometimes you might have api endpoints being served within the same traditional web app. Having a way of ignoring :edit and :new would be nice.

# routes/web.rb
modular_routes do
  resources :books
end

# routes/api.rb
modular_routes(api: true) do
  resources :books
end

vitoravelino avatar Sep 10 '21 12:09 vitoravelino