Sha256: 378d7cc4f29c91fac4851bb02f5c988cee14fba6a7188661ea627e294ed09654

Contents?: true

Size: 495 Bytes

Versions: 8

Compression:

Stored size: 495 Bytes

Contents

# frozen_string_literal: true

module Healthicons
  module Rails
    module ViewHelpers
      # Allow the healthcare icon to be called in rails, so icons can be added to the views
      #
      # @param icon [String] icon image name
      # @param options [Hash] additional attributes you want to apply to the SVG
      # @return [String] the SVG/XML contents of the icon
      def healthicon(icon, **options)
        Healthicons::Icon.call(icon, options)&.html_safe
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
healthicons-0.0.8 lib/healthicons/rails/view_helpers.rb
healthicons-0.0.7 lib/healthicons/rails/view_helpers.rb
healthicons-0.0.6 lib/healthicons/rails/view_helpers.rb
healthicons-0.0.5 lib/healthicons/rails/view_helpers.rb
healthicons-0.0.4 lib/healthicons/rails/view_helpers.rb
healthicons-0.0.3 lib/healthicons/rails/view_helpers.rb
healthicons-0.0.2 lib/healthicons/rails/view_helpers.rb
healthicons-0.0.1 lib/healthicons/rails/view_helpers.rb