You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm testing out the Turbo support and found the turbo_stream helper errors when passing a block in an ERB template.
Am I doing something wrong?
It works if I create the turbo stream HTML without the helper.
It works if I use the helper without a block.
hello.rb
classRoutes::Hello < Bridgetown::Rack::Routesroutedo |r|
# route: POST /hello/:namer.post"hello",Stringdo |name|
ifr.turbo_stream?r.respond_with_turbo_stream# Needed if not using the turbo_stream helper in the viewrender("hello",locals: {name: name})elser.redirect"/hello/#{name}"endendendend
hello.erb
<% turbo_stream.append "turbo-test" do %><p>Appended</p><%end%>
@candland Well, a couple of things. If you're using the render plugin for Roda, that's outside of Bridgetown's way of handling template rendering…Bridgetown's own ERB rendering solution supports capture.
I'm testing out the Turbo support and found the turbo_stream helper errors when passing a block in an ERB template.
Am I doing something wrong?
hello.rb
hello.erb
The text was updated successfully, but these errors were encountered: