By using ViewComponents one finds the possinility to also create a Stimulus Controller.
It took a while for me to find it out, how to make us of it in a Rails 8 application, together with propshaft and importmaps.
At the end it was quite easy, simply add following:
# config/initializers/assets.rb
Rails.application.config.assets.paths << Rails.root.join("app/components")
Rails.application.config.importmap.cache_sweepers << Rails.root.join("app/components")
# config/importmap.rb
pin_all_from "app/components", under: "controllers", to: ""