twitter-bootstrap-rails-cdn 1.0.2 → 1.0.3

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  Twitter Boostrap CDN support for Rails 3 and 4
4
4
 
5
+ *See below for details on using the new 3.0.0-RC1 version of bootstrap.*
6
+
5
7
  Serving Bootstrap from a publicly available [CDN](http://en.wikipedia.org/wiki/Content_Delivery_Network) has clear benefits:
6
8
 
7
9
  * **Speed**: Users will be able to download Bootstrap from the closest physical location.
@@ -93,6 +95,13 @@ twitter_bootstrap_stylesheet_link_tag :netdna, force: true
93
95
  twitter_bootstrap_javascript_include_tag :netdna, force: true
94
96
  ```
95
97
 
98
+ The default Bootstrap version will be 2.3.2 until the final release of 3.0.0, until then to use 3.0.0-RC1 just set the version in the options and force the use of a CDN in development.
99
+
100
+ ```ruby
101
+ twitter_bootstrap_stylesheet_link_tag :netdna, force: true, version: '3.0.0-RC1'
102
+ twitter_bootstrap_javascript_include_tag :netdna, force: true, version: '3.0.0-RC1'
103
+ ```
104
+
96
105
  ## License
97
106
 
98
107
  Copyright (c) 201 Nicholas Barthelemy
@@ -17,7 +17,7 @@ module TwitterBootstrap::Rails::Cdn
17
17
  def twitter_bootstrap_javascript_include_tag(host, options = {}, html_options = {})
18
18
  local = twitter_bootstrap_javascript_url(:local, options)
19
19
 
20
- if OFFLINE and !options.delete(:force)
20
+ if OFFLINE and !options[:force]
21
21
  javascript_include_tag(local, html_options)
22
22
  else
23
23
  [
@@ -31,8 +31,8 @@ module TwitterBootstrap::Rails::Cdn
31
31
  def twitter_bootstrap_stylesheet_include_tag(host, options = {}, html_options = {})
32
32
  local = twitter_bootstrap_stylesheet_url(:local, options)
33
33
 
34
- if OFFLINE and !options.delete(:force)
35
- stylesheet_link_tag(local, options)
34
+ if OFFLINE and !options[:force]
35
+ stylesheet_link_tag(local, html_options)
36
36
  else
37
37
  [ stylesheet_link_tag(twitter_bootstrap_stylesheet_url(host, options), html_options),
38
38
  javascript_tag("$(function(){ $('body').css('color') === 'rgb(51, 51, 51)' "+
@@ -44,13 +44,13 @@ module TwitterBootstrap::Rails::Cdn
44
44
  private
45
45
 
46
46
  def twitter_bootstrap_url(type, host, options = {})
47
- version = options.delete(:version) || BOOTSTRAP_VERSIONS.first
47
+ version = options[:version] || BOOTSTRAP_VERSIONS.first
48
48
 
49
49
  ext = ''
50
50
  if type == :css
51
- ext << '-combined' unless options.delete(:responsive) == false
51
+ ext << '-combined' unless options[:responsive] == false
52
52
  end
53
- ext << '.min' unless options.delete(:compressed) == false
53
+ ext << '.min' unless options[:compressed] == false
54
54
 
55
55
  {
56
56
  :netdna => "//netdna.bootstrapcdn.com/twitter-bootstrap/#{version}/#{type}/bootstrap#{ext}.#{type}",
@@ -1,7 +1,7 @@
1
1
  module TwitterBootstrap
2
2
  module Rails
3
3
  module Cdn
4
- VERSION = '1.0.2'
4
+ VERSION = '1.0.3'
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twitter-bootstrap-rails-cdn
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-07-26 00:00:00.000000000 Z
12
+ date: 2013-07-31 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: Twitter Boostrap CDN support for Rails 3 and 4
15
15
  email: