react-rails
react-rails copied to clipboard
Change the default behaviour of Camelized props
- [x] I have another issue to discuss.
In #409 we allowed an opt-in config to change from snake_case to camelCase. In #556 we exposed the function externally incase it needs to be used.
I believe it may be time to switch to camelCase as the default, this is because the generator makes camelCase components.
$ rails g react:component post snake_case:string
# create app/javascript/components/Post.js
propTypes: {
snakeCase: PropTypes.string
}
This would be part of a v3 release due to breaking backward compatibility if we chose to go for it.