New Discussion

Notifications

You’re not receiving notifications from this thread.

Is 'js.erb' approach obsolete? What are the alternatives?

1
Rails

Just like in the title, is using js.erb a bad practice? What are the best alternatives to manipulate the DOM?
I am trying to understand when to use each approach correctly, like stimulus or turbo streams etc.

I don't believe you'll be able to use .js.erb responses in Turbo going forward. They're pretty much replaced by TurboStreams. 👍

Join the discussion
Create an account Log in

Want to stay up-to-date with Ruby on Rails?

Join 89,127+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.