Add a rails helper for the new custom stream action
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
module TurboStreamsActionsHelper
|
||||
def set_css_variable(target, name:, value:)
|
||||
tag.turbo_stream target: target, action: "set_css_variable", name:, value:
|
||||
end
|
||||
end
|
||||
|
||||
Turbo::Streams::TagBuilder.prepend(TurboStreamsActionsHelper)
|
||||
Reference in New Issue
Block a user