instance method
append
Ruby on Rails 1.5.0
Since v1.3.3 Last seen in v2.0.23Signature
append(target, content = nil, **rendering, &block)
Append to the target in the dom identified with target either the content passed in or a rendering result determined by the rendering keyword arguments, the content in the block, or the rendering of the content as a record. Examples:
<%= turbo_stream.append "clearances", "<div id='clearance_5'>Append this to .clearances</div>" %>
<%= turbo_stream.append "clearances", clearance %>
<%= turbo_stream.append "clearances", partial: "clearances/unique_clearance", locals: { clearance: clearance } %>
<%= turbo_stream.append "clearances" do %>
<div id='clearance_5'>Append this to .clearances</div>
<% end %>
Parameters
-
targetreq -
contentopt = nil -
renderingkeyrest -
blockblock
Source
# File app/models/turbo/streams/tag_builder.rb, line 167
def append(target, content = nil, **rendering, &block)
action :append, target, content, **rendering, &block
end
Defined in app/models/turbo/streams/tag_builder.rb line 167
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in Turbo::Streams::TagBuilder