File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ class Railtie < ::Rails::Railtie
99 config . react . variant = ( ::Rails . env . production? ? :production : :development )
1010 config . react . addons = false
1111 config . react . jsx_transform_options = { }
12+ config . react . jsx_transformer_class = React ::JSX ::BabelTransformer
1213 # Server rendering:
1314 config . react . server_renderer_pool_size = 10
1415 config . react . server_renderer_timeout = 20 # seconds
@@ -23,6 +24,7 @@ class Railtie < ::Rails::Railtie
2324 # Include the react-rails view helper lazily
2425 initializer "react_rails.setup_view_helpers" , group : :all do |app |
2526 React ::JSX . transform_options = app . config . react . jsx_transform_options
27+ React ::JSX . transformer_class = app . config . react . jsx_transformer_class
2628 ActiveSupport . on_load ( :action_view ) do
2729 include ::React ::Rails ::ViewHelper
2830 end
You can’t perform that action at this time.
0 commit comments