class

ActionView::OutputBuffer

v7.2.3 - Show latest stable - Superclass: ActiveSupport::SafeBuffer

Used as a buffer for views

The main difference between this and ActiveSupport::SafeBuffer is for the methods `<<` and `safe_expr_append=` the inputs are checked for nil before they are assigned and `to_s` is called on the input. For example:

obuf = ActionView::OutputBuffer.new "hello"
obuf << 5
puts obuf # => "hello5"

sbuf = ActiveSupport::SafeBuffer.new "hello"
sbuf << 5
puts sbuf # => "hello\u0005"

Attributes

[R]raw_buffer

Files

  • actionview/lib/action_view/buffers.rb