Steps to reproduce
classMyController < ApplicationControllerdeffooprops=params.permit(:foo_bar,:baz_etc)rendercomponent: 'foo',props: props,camelize_props: trueendend
Note that the given props are not properly camelized when rendered to the React component. This is because React.camelize_props does not recognize ActionController::Parameters as a valid hash and returns it as-is.
Expected behavior
React.camelize_props should camelize instances of ActionController::Parameters.
Actual behavior
React.camelize_props does not camelize instances of ActionController::Parameters.
I was going to submit a PR, but I noticed that the gem spec only requires Rails 3.2, so I wasn't sure what the best approach might be for testing with a class that didn't appear until Rails 4.
Steps to reproduce
Note that the given props are not properly camelized when rendered to the React component. This is because
React.camelize_propsdoes not recognizeActionController::Parametersas a valid hash and returns it as-is.Expected behavior
React.camelize_propsshould camelize instances ofActionController::Parameters.Actual behavior
React.camelize_propsdoes not camelize instances ofActionController::Parameters.I was going to submit a PR, but I noticed that the gem spec only requires Rails 3.2, so I wasn't sure what the best approach might be for testing with a class that didn't appear until Rails 4.