Module: Bh::CdnHelper
- Defined in:
- lib/bh/helpers/cdn_helper.rb
Overview
Provides methods to retrieve the URLs of Bootstrap stylesheets and Javascript files from Bootstrap CDN
Instance Method Summary collapse
-
#bootstrap_css(options = {}) ⇒ String
The URL of the Bootstrap CSS file.
-
#bootstrap_js(options = {}) ⇒ String
The URL of the Bootstrap JS file.
-
#bootstrap_theme_css(options = {}) ⇒ String
The URL of the Bootstrap Theme CSS file.
-
#font_awesome_css(options = {}) ⇒ String
The URL of the Font Awesome CSS file.
Instance Method Details
#bootstrap_css(options = {}) ⇒ String
Returns the URL of the Bootstrap CSS file.
11 12 13 |
# File 'lib/bh/helpers/cdn_helper.rb', line 11 def bootstrap_css( = {}) bootstrap_asset .merge(name: 'bootstrap', extension: 'css') end |
#bootstrap_js(options = {}) ⇒ String
Returns the URL of the Bootstrap JS file.
39 40 41 |
# File 'lib/bh/helpers/cdn_helper.rb', line 39 def bootstrap_js( = {}) bootstrap_asset .merge(name: 'bootstrap', extension: 'js') end |
#bootstrap_theme_css(options = {}) ⇒ String
Returns the URL of the Bootstrap Theme CSS file.
20 21 22 |
# File 'lib/bh/helpers/cdn_helper.rb', line 20 def bootstrap_theme_css( = {}) bootstrap_asset .merge(name: 'bootstrap-theme', extension: 'css') end |
#font_awesome_css(options = {}) ⇒ String
Returns the URL of the Font Awesome CSS file.
30 31 32 |
# File 'lib/bh/helpers/cdn_helper.rb', line 30 def font_awesome_css( = {}) font_awesome_asset .merge(name: 'font-awesome', extension: 'css') end |