Sha256: 546be4f58d0dab4984dde6e789a601eed56c0d8145903bdd28bdca96fef5f273

Contents?: true

Size: 401 Bytes

Versions: 1

Compression:

Stored size: 401 Bytes

Contents

module Sociyal
  module Helpers
    extend ActiveSupport::Concern

    def yashare(opts = {})
      attrs = {
        charset: 'utf-8',
        type:    'text/javascript',
        src:     '//yastatic.net/share/share.js'
      }

      script = content_tag(:script, nil, attrs)
      widget = Sociyal::Widget.new(self, opts)
      html = [script, widget].join("\n")

      raw(html)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sociyal-1.0.0 lib/sociyal/helpers.rb