I just ported two rails apps from rails 5.2 to rails 7.0, and it caused me some headache and cost me some time to get the asset pipeline and a small ajax function (which just updates a table in a web page) working again. I had to do a lot of trial-and-error and googling other web pages. Since you ask for feedback on the guides pages, I’ll give some in order to improve the pages.
A general problem is that the pages – I admit that many docs have this problem nowadays – tends to tell “do this if you want that”, but never gives a comprehensible overview, picture of what is going on.
I’m also not sure what is the current syntax of including things, whether
//= require rails-ujs
import Rails from “@rails/ujs” Rails.start()
The latter worked, but I found this on some blog page somewhere in the internet, not in the guide.
On thing was that I had to learn that I had to turn turbolinks off, in order to get things work again, and that the guide was simply wrong in that detail, because it still talks about turbolinks, while rails 7 uses the newer framework turbo instead of turbolinks. Therefore, it takes a
attribute, and not a
as told in the guide, to turn turbo off and keep it from spoiling the ajax function. Given the fact, that turbo seems to heavily impact the page behaviour, the guide tells very little about this. And it does not tell how to get completely rid of it.
And I had to do a
yarn add @rails/ujs
and to change the application.js in order to get things running (while not yet really understanding sufficiently, what’s going on).
Similar difficulties with the asset pipeline.
E.g. it took me some time to understand, that this is done in two steps, first create things in products, and then pack them together.
And I did not get the pipeline working in development mode. Even in development mode I have to run assets:precompile to get things running. For the shere fact that I do not see a description about how things are supposed to work in development mode, and thus do not know where to start debugging.