Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Only pass
:request_id
option to Refresh Stream (#603)
When rendering `<turbo-stream>` elements for broadcasting, **omit** the `:request_id` partial-local variable. When rendered partials utilize [Action View strict locals][], the extra variable raises an error: ``` unknown local :request_id ``` By omitting the `:request_id` from the `Turbo::Broadcastable#broadcast_rendering_with_defaults`, it isn't passed as part of partial rendering. Likewise, since `broadcast_refresh` never renders a partial, but instead builds an empty `<turbo-stream action="refresh" request-id="..."></turbo-stream>` element, the `:request_id` local variable isn't necessary. [Action view strict locals]: https://guides.rubyonrails.org/action_view_overview.html#strict-locals
- Loading branch information