Skip to content

Commit

Permalink
Freeze css-loader to version below 7
Browse files Browse the repository at this point in the history
This is a minimal and temporary fix to prevent breaking changes in
css-loader v7
  • Loading branch information
ahangarha committed Apr 5, 2024
1 parent 1129c98 commit 4e5120f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/generators/react_on_rails/base_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ def add_yarn_dependencies
css_minimizer_webpack_plugin_version = node_major_version >= 18 ? "" : "@<6.0.0"
css_minimizer_webpack_plugin = "css-minimizer-webpack-plugin#{css_minimizer_webpack_plugin_version}"

run "yarn add css-loader '#{css_minimizer_webpack_plugin}' mini-css-extract-plugin style-loader"
run "yarn add 'css-loader@<7.0.0' '#{css_minimizer_webpack_plugin}' mini-css-extract-plugin style-loader"

puts "Adding dev dependencies"
run "yarn add -D @pmmmwh/react-refresh-webpack-plugin react-refresh"
Expand Down

0 comments on commit 4e5120f

Please sign in to comment.