Skip to content

Commit f598732

Browse files
committed
Improve Pro-only feature warning in spec/dummy initializer
Make it crystal clear that generated_component_packs_loading_strategy is a Pro-only feature and should NOT be used without a license. The setting is only present in spec/dummy because tests stub the ReactOnRailsPro constant.
1 parent 74fcb5c commit f598732

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

spec/dummy/config/initializers/react_on_rails.rb

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,9 @@ def self.adjust_props_for_client_side_hydration(component_name, props)
4242
config.components_subdirectory = "startup"
4343
config.auto_load_bundle = true
4444

45-
# For spec/dummy tests, we use :defer to prevent component registration race conditions.
46-
# This is explicitly set for testing purposes. Real user apps should rely on the Pro default (:async).
47-
# Note: This setting requires React on Rails Pro in production use.
45+
# IMPORTANT: generated_component_packs_loading_strategy is a React on Rails PRO feature.
46+
# This is set here ONLY for spec/dummy tests which stub ReactOnRailsPro constant.
47+
# DO NOT use this setting in production without a Pro license.
48+
# We use :defer to prevent component registration race conditions during testing.
4849
config.generated_component_packs_loading_strategy = :defer
4950
end

0 commit comments

Comments
 (0)