Skip to content

Instantly share code, notes, and snippets.

@ftes
Created October 3, 2021 19:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ftes/84e01c6b4b1258dedafd4556cd2b9f88 to your computer and use it in GitHub Desktop.
Save ftes/84e01c6b4b1258dedafd4556cd2b9f88 to your computer and use it in GitHub Desktop.
Drag 'n drop on the PETAL(S) stack
if @dragged.target == :live_view do
"hook.pushEvent('#{@dragged.name}', {from, to});"
else
"hook.pushEventTo('#{@dragged.target}', '#{@dragged.name}', {from, to});"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment