Just got some ideas from zurb-foundation
gem
and fetched javascript files from http://cdnjs.com
and made jquery available in any rails project,
or even just project with sprockets
support.
gem 'fresh-backbone'
in yourGemfile
//= require
underscore, backbone and jquery from yourapplication.js
- Have your backbone as you like
gem 'fresh-backbone'
in yourGemfile
, yepGemfile
in your sinatra project:
source "https://rubygems.org"
gem "sinatra"
gem "sinatra-asset-pipeline"
gem "sprockets" # This line should go before asset gems!
gem "fresh-backbone" # The gem you're trying to use
- In your sinatra application:
Bundler.require
require "sinatra/asset_pipeline"
require "erb"
register Sinatra::AssetPipeline
get "/" do
erb :index
end
- Run application and have backbone files!