I am new to the react . Here , what I have tried.
onaddRow(e, id) {
const addData = this.props.lowData;
const tempObj = {
id: 'L1',
technologyId: 0,
technology: '',
type: '',
numberOfQuestions: ''
}
addData.push(tempObj);
}
this.props.lowData is an array of the objects . So, I want to add an object in this .
So, I tried the following way but it was not working , can any one suggest me how can I do this ?
addDataobject but in your question you say you want to add tothis.props.lowData; which do you want to add to?this.props.lowDatais an array?onaddRow()was properly called? Because the function body looks okay to me.