Sha256: a33c2024ce9d047c805c0f88b42211f3cf7f9df3dcec78786fd02580cd36ca94

Contents?: true

Size: 355 Bytes

Versions: 5

Compression:

Stored size: 355 Bytes

Contents

module Riif
  module Rails
    class Renderer
      ActionController::Renderers.add :iif do |iif_string, options|
        filename = options[:filename] || options[:template]
        send_data(
          iif_string,
          filename: "#{filename}.iif",
          type: Mime::IIF,
          disposition: 'attachment'
        )
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
riif-0.6.0 lib/riif/rails/renderer.rb
riif-0.5.0 lib/riif/rails/renderer.rb
riif-0.4.0 lib/riif/rails/renderer.rb
riif-0.3.0 lib/riif/rails/renderer.rb
riif-0.2.0 lib/riif/rails/renderer.rb