Sha256: 6e953a45ee4bb7f3cb41f2c9c94db37a71aad705be899c32048d8e0ac9022136

Contents?: true

Size: 284 Bytes

Versions: 2

Compression:

Stored size: 284 Bytes

Contents

module Typekit
  module ViewHelper
    def typekit(kit_id)
      return if kit_id == '- YOUR KIT ID HERE -'
      content_tag :script, nil, src: "//use.typekit.com/#{kit_id}.js", async: true
      content_tag :script, "try{Typekit.load({ async: true });}catch(e){}"
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
typekit-rails-1.0.0 app/helpers/typekit/view_helper.rb
typekit-rails-0.0.4 app/helpers/typekit/view_helper.rb