class SurveyQuestion extends React.Component {
constructor(props) {
model.onComplete.add(function(result) {
return <TestEmpty message="test" />;
}
});
}
I am new to react, apologize if this is basic question, Is there any chance that if I could return component inside the constructor function, please? When it is completed then return component.
I tried with my code, it is not working and no error message.
modeland what ismodel.onComplete? And also - why you need theresultin the function if you don't have any usage of that variable?addshould receive? And again - what ismodel?