README.md in react-rails-1.4.2 vs README.md in react-rails-1.5.0

- old
+ new

@@ -24,11 +24,11 @@ ## Installation Add `react-rails` to your gemfile: ```ruby -gem 'react-rails', '~> 1.4.0' +gem 'react-rails', '~> 1.5.0' ``` Next, run the installation script: ```bash @@ -100,11 +100,11 @@ You can use babel's [transformers](http://babeljs.io/docs/advanced/transformers/) and [custom plugins](http://babeljs.io/docs/advanced/plugins/), and pass [options](http://babeljs.io/docs/usage/options/) to the babel transpiler adding following configurations: ```ruby config.react.jsx_transform_options = { - blacklist: ['spec.functionName', 'validation.react'], # default options + blacklist: ['spec.functionName', 'validation.react', 'strict'], # default options optional: ["transformerName"], # pass extra babel options whitelist: ["useStrict"] # even more options } ``` Under the hood, `react-rails` uses [ruby-babel-transpiler](https://github.com/babel/ruby-babel-transpiler), for transformation. @@ -203,9 +203,17 @@ ``` - On MRI, use `therubyracer` for the best performance (see [discussion](https://github.com/reactjs/react-rails/pull/290)) - On MRI, you'll get a deadlock with `pool_size` > 1 - If you're using JRuby, you can increase `pool_size` to have real multi-threaded rendering. + +You can configure camelize_props option and pass props with an underscored hash from rails but get a camelized hash in jsx : + +```ruby +MyApp::Application.configure do + config.react.camelize_props = true #default false +end +``` ### Rendering components instead of views Components can also be prerendered directly from a controller action with the custom `component` renderer. For example: