Skip to content

Conversation

@tk0miya
Copy link

@tk0miya tk0miya commented Nov 16, 2025

Now asset files are installed only in development environment. Therefore, the debug mode cannot be used in production environment.

This change makes it possible to install asset files when the debug mode is enabled, regardless of the environment.

ref: #61

Now asset files are installed only in development environment. Therefore,
the debug mode cannot be used in production environment.

This change makes it possible to install asset files when the debug mode
is enabled, regardless of the environment.

ref: marcoroth#61
@marcoroth
Copy link
Owner

marcoroth commented Nov 16, 2025

Thanks for the pull request @tk0miya!

I'm really wondering if we should allow to ship the ReActionView assets in production by default.

In the future, it will make sense to run ReActionView in production. But for the time being where it's only the Dev Tools I'm not sure it makes sense to allow it. Also, because all the paths etc. are not going to work, since it will use the paths on disk from the deployed host.

Maybe we can make it opt-in, so it's more intentional?

@tk0miya
Copy link
Author

tk0miya commented Nov 17, 2025

In my case, I've used the Rails' production environment not only for production usage.

For example, we have four servers: development, QA, staging, and production. On these servers, our Rails application is running in the production environment. And I tried to enable reactionview only on the development server.

Actually, I enabled debug_mode like such configuration:

# Enable debug_mode via RAILS_ENV or settings.yml (config gem)
config.debug_mode = Rails.env.development? || Settings.reactionview.enabled

I'm really wondering if we should allow to ship the ReActionView assets in production by default.

In the future, it will make sense to run ReActionView in production. But for the time being where it's only the Dev Tools I'm not sure it makes sense to allow it. Also, because all the paths etc. are not going to work, since it will use the paths on disk from the deployed host.

The current implementation of reactionview installs ERB handler if intercept_erb is enabled regardless to the RAILS_ENV. Is this intended? I feel this is intended and designed for future work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants