You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enhance configuration documentation and clarify directory structure for server and client bundles
- Added detailed comments in configuration.md to explain server bundle output path and security measures for loading server bundles.
- Introduced examples for organizing client and server assets to improve clarity for users.
- Updated comments in base_generator.rb and react_with_redux_generator.rb to reflect changes from 'auto-registration' to 'auto-bundling' terminology for consistency.
These changes aim to improve the understanding of asset management and security practices within the React on Rails framework.
Copy file name to clipboardExpand all lines: docs/guides/configuration.md
+42-7Lines changed: 42 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -129,16 +129,51 @@ ReactOnRails.configure do |config|
129
129
# This manifest file is automatically generated by the React Server Components Webpack plugin. Only set this if you've configured the plugin to use a different filename.
# When enabled, enforces that server bundles are only loaded from private, designated locations
138
-
# to prevent potential security risks from loading untrusted server-side code.
139
-
# Default is false for backward compatibility.
142
+
# When set to true, React on Rails will only load server bundles from private, explicitly configured directories (such as `ssr-generated`), and will raise an error if a server bundle is found in a public or untrusted location. This helps prevent accidental or malicious execution of untrusted JavaScript on the server, and is strongly recommended for production environments. And prevent leakage of server-side code to the client (Especially in the case of RSC).
143
+
# Default is false for backward compatibility, but enabling this option is a best practice for security.
0 commit comments