Skip to content

Commit f4eaf69

Browse files
committed
Remove immediate_hydration from ReactOnRails configuration
Removes immediate_hydration configuration option from ReactOnRails core. This feature is now automatically enabled for Pro users and disabled for non-Pro users without requiring any configuration. Removed from: - Default configuration values - attr_accessor list - initialize parameters - initialize assignments
1 parent 741c423 commit f4eaf69

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

lib/react_on_rails/configuration.rb

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,6 @@ def self.configuration
4141
components_subdirectory: nil,
4242
make_generated_server_bundle_the_entrypoint: false,
4343
defer_generated_component_packs: false,
44-
# React on Rails Pro (licensed) feature - enables immediate hydration of React components
45-
immediate_hydration: false,
4644
# Maximum time in milliseconds to wait for client-side component registration after page load.
4745
# If exceeded, an error will be thrown for server-side rendered components not registered on the client.
4846
# Set to 0 to disable the timeout and wait indefinitely for component registration.
@@ -64,7 +62,7 @@ class Configuration
6462
:server_render_method, :random_dom_id, :auto_load_bundle,
6563
:same_bundle_for_client_and_server, :rendering_props_extension,
6664
:make_generated_server_bundle_the_entrypoint,
67-
:generated_component_packs_loading_strategy, :immediate_hydration,
65+
:generated_component_packs_loading_strategy,
6866
:component_registry_timeout,
6967
:server_bundle_output_path, :enforce_private_server_bundles
7068

@@ -81,7 +79,7 @@ def initialize(node_modules_location: nil, server_bundle_js_file: nil, prerender
8179
same_bundle_for_client_and_server: nil,
8280
i18n_dir: nil, i18n_yml_dir: nil, i18n_output_format: nil, i18n_yml_safe_load_options: nil,
8381
random_dom_id: nil, server_render_method: nil, rendering_props_extension: nil,
84-
components_subdirectory: nil, auto_load_bundle: nil, immediate_hydration: nil,
82+
components_subdirectory: nil, auto_load_bundle: nil,
8583
component_registry_timeout: nil, server_bundle_output_path: nil, enforce_private_server_bundles: nil)
8684
self.node_modules_location = node_modules_location.present? ? node_modules_location : Rails.root
8785
self.generated_assets_dirs = generated_assets_dirs
@@ -122,7 +120,6 @@ def initialize(node_modules_location: nil, server_bundle_js_file: nil, prerender
122120
self.auto_load_bundle = auto_load_bundle
123121
self.make_generated_server_bundle_the_entrypoint = make_generated_server_bundle_the_entrypoint
124122
self.defer_generated_component_packs = defer_generated_component_packs
125-
self.immediate_hydration = immediate_hydration
126123
self.generated_component_packs_loading_strategy = generated_component_packs_loading_strategy
127124
self.server_bundle_output_path = server_bundle_output_path
128125
self.enforce_private_server_bundles = enforce_private_server_bundles

0 commit comments

Comments
 (0)