Good day people, hoping you’re having a great day.
So, i have a model that has a simple after_create_commit
that broadcasts the object to the DOM via Streams.
The partial, references a url to pass it as a data-
attribute for the Stimulus controller. I noticed, when the new partial is rendered to the DOM, it has an exmple.org
set as it’s host. Here is how it looks like
I tried setting the host
in the Rails default_url_options. But, that does not seem to work. However, if render the url as in Rails.application.routes.url_helpers.THE_URL
. All works fine, is there anyway to fix this?
Thank you for reading this!