Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ git_source(:github) { |repo| "https://github.com/#{repo}.git" }

ruby "3.3.4"

gem "react_on_rails", "16.0.1.rc.4"
gem "react_on_rails", "16.1.1"
gem "shakapacker", "8.2.0"

# Bundle edge Rails instead: gem "rails", github: "rails/rails"
Expand Down
114 changes: 58 additions & 56 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -8,65 +8,65 @@ GIT
GEM
remote: https://rubygems.org/
specs:
actioncable (8.0.2.1)
actionpack (= 8.0.2.1)
activesupport (= 8.0.2.1)
actioncable (8.0.3)
actionpack (= 8.0.3)
activesupport (= 8.0.3)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
zeitwerk (~> 2.6)
actionmailbox (8.0.2.1)
actionpack (= 8.0.2.1)
activejob (= 8.0.2.1)
activerecord (= 8.0.2.1)
activestorage (= 8.0.2.1)
activesupport (= 8.0.2.1)
actionmailbox (8.0.3)
actionpack (= 8.0.3)
activejob (= 8.0.3)
activerecord (= 8.0.3)
activestorage (= 8.0.3)
activesupport (= 8.0.3)
mail (>= 2.8.0)
actionmailer (8.0.2.1)
actionpack (= 8.0.2.1)
actionview (= 8.0.2.1)
activejob (= 8.0.2.1)
activesupport (= 8.0.2.1)
actionmailer (8.0.3)
actionpack (= 8.0.3)
actionview (= 8.0.3)
activejob (= 8.0.3)
activesupport (= 8.0.3)
mail (>= 2.8.0)
rails-dom-testing (~> 2.2)
actionpack (8.0.2.1)
actionview (= 8.0.2.1)
activesupport (= 8.0.2.1)
actionpack (8.0.3)
actionview (= 8.0.3)
activesupport (= 8.0.3)
nokogiri (>= 1.8.5)
rack (>= 2.2.4)
rack-session (>= 1.0.1)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
useragent (~> 0.16)
actiontext (8.0.2.1)
actionpack (= 8.0.2.1)
activerecord (= 8.0.2.1)
activestorage (= 8.0.2.1)
activesupport (= 8.0.2.1)
actiontext (8.0.3)
actionpack (= 8.0.3)
activerecord (= 8.0.3)
activestorage (= 8.0.3)
activesupport (= 8.0.3)
globalid (>= 0.6.0)
nokogiri (>= 1.8.5)
actionview (8.0.2.1)
activesupport (= 8.0.2.1)
actionview (8.0.3)
activesupport (= 8.0.3)
builder (~> 3.1)
erubi (~> 1.11)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
activejob (8.0.2.1)
activesupport (= 8.0.2.1)
activejob (8.0.3)
activesupport (= 8.0.3)
globalid (>= 0.3.6)
activemodel (8.0.2.1)
activesupport (= 8.0.2.1)
activerecord (8.0.2.1)
activemodel (= 8.0.2.1)
activesupport (= 8.0.2.1)
activemodel (8.0.3)
activesupport (= 8.0.3)
activerecord (8.0.3)
activemodel (= 8.0.3)
activesupport (= 8.0.3)
timeout (>= 0.4.0)
activestorage (8.0.2.1)
actionpack (= 8.0.2.1)
activejob (= 8.0.2.1)
activerecord (= 8.0.2.1)
activesupport (= 8.0.2.1)
activestorage (8.0.3)
actionpack (= 8.0.3)
activejob (= 8.0.3)
activerecord (= 8.0.3)
activesupport (= 8.0.3)
marcel (~> 1.0)
activesupport (8.0.2.1)
activesupport (8.0.3)
base64
benchmark (>= 0.3)
bigdecimal
Expand Down Expand Up @@ -154,7 +154,7 @@ GEM
generator_spec (0.10.0)
activesupport (>= 3.0.0)
railties (>= 3.0.0)
globalid (1.2.1)
globalid (1.3.0)
activesupport (>= 6.1)
i18n (1.14.7)
concurrent-ruby (~> 1.0)
Expand Down Expand Up @@ -253,20 +253,20 @@ GEM
rack (>= 1.3)
rackup (2.2.1)
rack (>= 3)
rails (8.0.2.1)
actioncable (= 8.0.2.1)
actionmailbox (= 8.0.2.1)
actionmailer (= 8.0.2.1)
actionpack (= 8.0.2.1)
actiontext (= 8.0.2.1)
actionview (= 8.0.2.1)
activejob (= 8.0.2.1)
activemodel (= 8.0.2.1)
activerecord (= 8.0.2.1)
activestorage (= 8.0.2.1)
activesupport (= 8.0.2.1)
rails (8.0.3)
actioncable (= 8.0.3)
actionmailbox (= 8.0.3)
actionmailer (= 8.0.3)
actionpack (= 8.0.3)
actiontext (= 8.0.3)
actionview (= 8.0.3)
activejob (= 8.0.3)
activemodel (= 8.0.3)
activerecord (= 8.0.3)
activestorage (= 8.0.3)
activesupport (= 8.0.3)
bundler (>= 1.15.0)
railties (= 8.0.2.1)
railties (= 8.0.3)
rails-dom-testing (2.3.0)
activesupport (>= 5.0.0)
minitest
Expand All @@ -282,13 +282,14 @@ GEM
json
require_all (~> 3.0)
ruby-progressbar
railties (8.0.2.1)
actionpack (= 8.0.2.1)
activesupport (= 8.0.2.1)
railties (8.0.3)
actionpack (= 8.0.3)
activesupport (= 8.0.3)
irb (~> 1.13)
rackup (>= 1.0.0)
rake (>= 12.2)
thor (~> 1.0, >= 1.2.2)
tsort (>= 0.2)
zeitwerk (~> 2.6)
rainbow (3.1.1)
rake (13.3.0)
Expand All @@ -298,7 +299,7 @@ GEM
rdoc (6.14.2)
erb
psych (>= 4.0.0)
react_on_rails (16.0.1.rc.4)
react_on_rails (16.1.1)
addressable
connection_pool
execjs (~> 2.5)
Expand Down Expand Up @@ -425,6 +426,7 @@ GEM
tins (1.33.0)
bigdecimal
sync
tsort (0.2.0)
turbo-rails (2.0.11)
actionpack (>= 6.0.0)
railties (>= 6.0.0)
Expand Down Expand Up @@ -485,7 +487,7 @@ DEPENDENCIES
rails-html-sanitizer
rails_best_practices
rainbow
react_on_rails (= 16.0.1.rc.4)
react_on_rails (= 16.1.1)
redcarpet
redis (~> 5.0)
rspec-rails (~> 6.0.0)
Expand Down
14 changes: 4 additions & 10 deletions bin/dev
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#
# Each command uses a specific Procfile for process management:
# - bin/dev (default/hmr): Uses Procfile.dev
# - bin/dev static: Uses Procfile.dev-static-assets-assets
# - bin/dev static: Uses Procfile.dev-static-assets
# - bin/dev prod: Uses Procfile.dev-prod-assets
#
# To customize development environment:
Expand All @@ -18,14 +18,8 @@
# 3. Extend ReactOnRails::Dev classes in your Rails app for advanced customization
# 4. Use classes directly: ReactOnRails::Dev::ServerManager.start(:development, "Custom.procfile")

begin
require "bundler/setup"
require "react_on_rails/dev"
rescue LoadError
# Fallback for when gem is not yet installed
puts "Loading ReactOnRails development tools..."
require_relative "../../lib/react_on_rails/dev"
end
require "bundler/setup"
require "react_on_rails/dev"

# Main execution
ReactOnRails::Dev::ServerManager.run_from_command_line(ARGV)
ReactOnRails::Dev::ServerManager.run_from_command_line(ARGV)
1 change: 1 addition & 0 deletions config/webpack/clientWebpackConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,4 @@ const configureClient = () => {
};

module.exports = configureClient;

28 changes: 28 additions & 0 deletions config/webpack/commonWebpackConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,37 @@ const scssConfigIndex = baseClientWebpackConfig.module.rules.findIndex((config)
'.scss'.match(config.test),
);

// Configure sass-loader to use the modern API
const scssRule = baseClientWebpackConfig.module.rules[scssConfigIndex];
const sassLoaderIndex = scssRule.use.findIndex((loader) => {
if (typeof loader === 'string') {
return loader.includes('sass-loader');
}
return loader.loader && loader.loader.includes('sass-loader');
});

if (sassLoaderIndex !== -1) {
const sassLoader = scssRule.use[sassLoaderIndex];
if (typeof sassLoader === 'string') {
scssRule.use[sassLoaderIndex] = {
loader: sassLoader,
options: {
api: 'modern',
sassOptions: {
includePaths: []
}
}
};
} else {
sassLoader.options = sassLoader.options || {};
sassLoader.options.api = 'modern';
}
}

baseClientWebpackConfig.module.rules[scssConfigIndex].use.push(sassLoaderConfig);

// Copy the object using merge b/c the baseClientWebpackConfig and commonOptions are mutable globals
const commonWebpackConfig = () => merge({}, baseClientWebpackConfig, commonOptions, ignoreWarningsConfig);

module.exports = commonWebpackConfig;

1 change: 1 addition & 0 deletions config/webpack/development.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@ const developmentEnvOnly = (clientWebpackConfig, _serverWebpackConfig) => {
};

module.exports = webpackConfig(developmentEnvOnly);

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
"react": "^19.0.0",
"react-dom": "^19.0.0",
"react-intl": "^6.4.4",
"react-on-rails": "16.0.1-rc.4",
"react-on-rails": "16.1.1",
"react-redux": "^8.1.0",
"react-router": "^6.13.0",
"react-router-dom": "^6.13.0",
Expand Down
Loading