since rt-repeat containing tags are emitted as an array, they can't be root nodes, because React wants the result of the render function be an actual component, not an array of components.
Example:
<div rt-repeat="a in [1,2,3]">{a}</div>
is translated into:
var templateRT = function () {
function repeatA1(a, aIndex) {
return React.createElement('div', {}, a);
}
return _.map([1, 2, 3], repeatA1.bind(this));
};
but the following error is thrown when used:
Invariant Violation: Constructor.render(): A valid ReactComponent must be returned. You may have returned undefined, an array or some other invalid object.
since
rt-repeat
containing tags are emitted as an array, they can't be root nodes, because React wants the result of the render function be an actual component, not an array of components.Example:
is translated into:
but the following error is thrown when used: