Sustainable Web Development with Ruby on Rails is not a Rails tutorial, so don't buy it thinking you'll be learning about the new features of Rails 7. I don't have much more experience with them than you do! But it's been about two years since the original came out so the book benefits from an update.
The Rails 7 version of the book is pretty similar to the original, however here is what has changed:
All code samples are updated to use Rails features that are not deprecated in Rails 7. There weren't a lot of these.
Removed guidance to skip the listen and spring gems as Rails 7 no longer includes them by default.
Added guidance around using instance variables from controllers to help manage UI state.
You no longer need to disable remote forms by default as they are no longer the default in Rails 7.
The way to configure Postgres to use
TIMESTAMP WITH TIME ZONEhas changed and is more of a first-class API in Rails 7.
Softer guidance around using React and a bit stronger suggestion to consider Hotwire. While I don't have experience with Hotwire, I no longer think "just use React" is universally good advice for a Rails app. Hotwire is likely to be well-supported by the Rails team and have better compatibility with Rails than React, even though React is more widely understood.
More nuanced guidance around nested routes, in particular acknowledging that specialized content-only pages might benefit from a nested route namespace.
I created several gems based on some code in the book. Those gems are referenced when the concepts are discussed, but the full code for stuff like
confidence_checkis still there in the book. The gems are: