Closed dfguo closed 9 years ago
Sometimes we define multiple component classes in one file since they won't be reused anywhere else, but when we use it in react-template, we are forced to separate those classes in different files. Is there anyway to do:
component.coffee
ComponentA = React.createClass render: -> rtA.apply(this) ComponentB = React.createClass render: -> rtB.apply(this)
componentA.rt
<ComponentB />
componentB.rt
<div> hello </div>
Next version adds support for jsrt, inline rt which could solve your issue.
that's good to hear. thanks
Sometimes we define multiple component classes in one file since they won't be reused anywhere else, but when we use it in react-template, we are forced to separate those classes in different files. Is there anyway to do:
component.coffee
componentA.rt
componentB.rt