Sha256: 478f89c3f189b53d1f6f48e7bae9e44d55ad8f566a40f34f70bfa2b201a6b67c

Contents?: true

Size: 1.55 KB

Versions: 2

Compression:

Stored size: 1.55 KB

Contents

-# Grab Google CDN's jQuery, with a protocol relative URL
-# Looks for google_api_key first in ENV['GOOGLE_API_KEY'] then in config/google.yml
-# remote_jquery and local_jquery helpers use minified jquery unless Rails.env is development
- if !google_api_key.blank?
  = javascript_include_tag "//www.google.com/jsapi?key=#{google_api_key}"
  :javascript
    google.load(#{ remote_jquery("1.5.1") });
- else
  = javascript_include_tag "//ajax.googleapis.com/ajax/libs/jquery/#{ local_jquery("1.5.1") }"

-# fall back to local jQuery if necessary
:javascript
  !window.jQuery && document.write(unescape('%3Cscript src="/javascripts/jquery.min.js"%3E%3C/script%3E'))
  
= javascript_include_tag 'rails', 'plugins', 'application'

-# Fix any <img> or .png_bg bg-images. Also, please read goo.gl/mZiyb
/[if lt IE 7 ]
  = javascript_include_tag 'dd_belatedpng.js'
  :javascript
    //DD_belatedPNG.fix('img, .png_bg');
    
-#  Append your own using content_for :javascripts
= yield :javascripts

-# asynchronous google analytics: mathiasbynens.be/notes/async-analytics-snippet
-# Looks for google_account_id first in ENV['GOOGLE_ACCOUNT_ID'] then in config/google.yml
- if !google_account_id.blank?
  :javascript
    var _gaq = [['_setAccount', '#{google_account_id}'], ['_trackPageview']];
    (function(d, t) {
      var g = d.createElement(t),
          s = d.getElementsByTagName(t)[0];
      g.async = true;
      g.src = ('https:' == location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
      s.parentNode.insertBefore(g, s);
    })(document, 'script');

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
html5-boilerplate-0.3.2 templates/project/_javascripts.html.haml
html5-boilerplate-0.3.1 templates/project/_javascripts.html.haml