Skip to content

Commit d0033c3

Browse files
authored
Small doc fixes regarding i18n (#907)
1 parent 4ceae89 commit d0033c3

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

lib/generators/react_on_rails/templates/base/base/config/initializers/react_on_rails.rb.tt

+2
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,8 @@ ReactOnRails.configure do |config|
6565
# Replace the following line to the location where you keep translation.js & default.js for use
6666
# by the npm packages react-intl. Be sure this directory exists!
6767
# config.i18n_dir = Rails.root.join("client", "app", "libs", "i18n")
68+
# If not using the i18n feature, then leave this section commented out or set the value
69+
# of config.i18n_dir to nil.
6870
#
6971
# Replace the following line to the location where you keep your client i18n yml files
7072
# that will source for automatic generation on translations.js & default.js

lib/react_on_rails/configuration.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def self.check_i18n_directory_exists
2424

2525
raise "Error configuring /config/react_on_rails.rb: invalid value for `config.i18n_dir`. "\
2626
"Directory does not exist: #{@configuration.i18n_dir}. Set to value to nil or comment it "\
27-
"out if not using this i18n with React on Rails."
27+
"out if not using the React on Rails i18n feature."
2828
end
2929

3030
def self.check_i18n_yml_directory_exists

spec/dummy/Gemfile.lock

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
react_on_rails (8.0.6.rc.0)
4+
react_on_rails (8.0.6)
55
addressable
66
connection_pool
77
execjs (~> 2.5)
@@ -329,4 +329,4 @@ DEPENDENCIES
329329
webpacker_lite (= 2.1.0)
330330

331331
BUNDLED WITH
332-
1.15.1
332+
1.15.3

spec/dummy/config/initializers/react_on_rails.rb

+2-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ def self.custom_context(view_context)
5151
################################################################################
5252
# SERVER RENDERING OPTIONS
5353
################################################################################
54-
5554
# If set to true, this forces Rails to reload the server bundle if it is modified
5655
config.development_mode = Rails.env.development?
5756

@@ -79,6 +78,8 @@ def self.custom_context(view_context)
7978
# Replace the following line to the location where you keep translation.js & default.js for use
8079
# by the npm packages react-intl. Be sure this directory exists!
8180
# config.i18n_dir = Rails.root.join("client", "app", "libs", "i18n")
81+
# If not using the i18n feature, then leave this section commented out or set the value
82+
# of config.i18n_dir to nil.
8283
#
8384
# Replace the following line to the location where you keep your client i18n yml files
8485
# that will source for automatic generation on translations.js & default.js

0 commit comments

Comments
 (0)