hyper-react icon indicating copy to clipboard operation
hyper-react copied to clipboard

class: does not work well as a parameter for application classes

Open sollycatprint opened this issue 9 years ago • 2 comments

From @catmando on December 15, 2015 2:36

If you specify a parameter name as :class it gets translated to :className before handed over to the component.

So if you want to receive a parameter called :class you have to declare it as :className

This is happening because of some translation needed for react.js components (where they expect className rather than class.) Could get tricky...

Anyway its not a patch level fix, as in most cases if you are trying to pass :class you really want to be just collecting all other attributes, and then passing them all along to the lower level components.

Copied from original issue: zetachang/react.rb#101

sollycatprint avatar Jun 13 '16 13:06 sollycatprint

From @catmando on December 15, 2015 15:18

I don't even think we need this for 0.9, if it get fixed before then great, if not, oh well.

sollycatprint avatar Jun 13 '16 13:06 sollycatprint

related to #108

catmando avatar Sep 07 '16 01:09 catmando