March 15, 2021
Rails 6.1 offically fixed large routes file! Here is an example of how to do this:
Rails.application.routes.draw do draw(:api) root 'home#index' end
namespace :api, defaults: { format: :json } do devise_for :users end