Link_to problem and I cannot see why

I had some code from Rails 7.0.4 running with

@hotwired/stimulus”: “^3.1.0”,
@hotwired/turbo-rails”: “^7.1.3”,

The gist of it was deleting a resource with a custom confirm, copped from a blog post. It worked great! I moved the same link to a different App, running Rails 7.0.4 and

@hotwired/stimulus”: “^3.2.1”,
@hotwired/turbo-rails”: “^7.2.4”,

But the link code no longer works at all. Basically, none of the Turbo events trigger. So my Stimuaus controller is named fine, and so I was thinking this little ditty would just, but nope. My delete link just deletes the resource, happy as a clam, and no confirm ever pops up. Has something changed during these updates and I am just missing out on those changes, making this code broken?

This link works, ie) a confirm from the browser pops up:

      <%= link_to "Delete School", "#", data: { "turbo-method": "delete", "turbo-confirm": "Are you sure you want to delete the school?" } %>

But this one, ignores Turbo and just deletes the resource! Why?

      <%= link_to "Delete Turbo Style", "#", data: { 'turbo-method': "delete", 'school-target': "link", action: "turbo:click->school#captureClick turbo:before-fetch-request@document->school#deleteAndHide" } %>

I must be blind. Not getting it. Nothing in my stimulus controller gets hit. No captureClick or deleteAndHide.

I am frustrated!

I might suggest temporarily downgrading turbo-rails to the version you know that worked to validate it’s related to the turbo-rails and not something else.

Hmm… yes… that could in fact be a thing I do… thanks. Will report back.

if you want your stimulus to trigger in data : { controller: name_of_stimulus, action: ‘action#name_of_stimulus’ }

Ya. I would not be writing here if that actually worked… but thanks! I have made a few hundred Stimulus controllers and actions in them, but this is the first time one has failed me with the only thing that has changed (at least in my mind) is the stimulus codebase itself. Hence my question.