Skip to content

Commit b3c0a38

Browse files
linting
1 parent 4600fbd commit b3c0a38

File tree

2 files changed

+2
-12
lines changed

2 files changed

+2
-12
lines changed

lib/react_on_rails/utils.rb

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -90,21 +90,12 @@ def self.bundle_js_file_path(bundle_name)
9090
else
9191
# Default to the non-hashed name in the specified output directory, which, for legacy
9292
# React on Rails, this is the output directory picked up by the asset pipeline.
93-
# For Webpacker, this is the public output path defined in the webpacker.yml file.
93+
# For Shakapacker, this is the public output path defined in the (shaka/web)packer.yml file.
9494
File.join(generated_assets_full_path, bundle_name)
9595
end
9696
end
9797

9898
def self.server_bundle_js_file_path
99-
# Either:
100-
# 1. Using same bundle for both server and client, so server bundle will be hashed in manifest
101-
# 2. Using a different bundle (different Webpack config), so file is not hashed, and
102-
# bundle_js_path will throw so the default path is used without a hash.
103-
# 3. The third option of having the server bundle hashed and a different configuration than
104-
# the client bundle is not supported for 2 reasons:
105-
# a. The webpack manifest plugin would have a race condition where the same manifest.json
106-
# is edited by both the webpack-dev-server
107-
# b. There is no good reason to hash the server bundle name.
10899
return @server_bundle_path if @server_bundle_path && !Rails.env.development?
109100

110101
bundle_name = ReactOnRails.configuration.server_bundle_js_file

node_package/src/ReactOnRails.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -257,8 +257,7 @@ ctx.ReactOnRails = {
257257
},
258258

259259
/**
260-
* Used by server rendering by Rails
261-
* @param options
260+
* Used by rsc payload generation by Rails
262261
*/
263262
// eslint-disable-next-line @typescript-eslint/no-unused-vars
264263
serverRenderRSCReactComponent(options: RenderParams): PassThrough {

0 commit comments

Comments
 (0)