Skip to content
loading...

re: Building a Rails App With Multiple Subdomains VIEW POST

FULL DISCUSSION
 

Wow, this is such a new approach to use subdomain constraint. I've always used it like this when building APIs:

namespace 'api', defaults: { format: 'json' }, constraints: { subdomain: /api/ }, path: '/' do
  # routes
end

and always forced myself to go this way when having multiple subdomains. Good to know there're more ways to do this!

Thanks for sharing :D

code of conduct - report abuse