Globber
Utilize the ruby on rails environment backed by any remote API!
Installation
In your Gemfile
:
gem 'globber'
Setup options:
Automagically
- Run
rails g globber:install
in the root directory of your project - Open
config/initializers/globber.rb
and set yourbase_uri
Manually (not as magical)
In config/routes.rb
:
mount Globber::Engine => "/"
In config/initializers/globber.rb
:
Globber.configure do |c|
c.base_uri = 'http://api.yoursite.com'
end
Now whichever route is passed to rails will be mapped to your API server.
That's it!