Assign reactive data from createContainer to component's state

Hi guys, so using createContainer is the standard method for retrieving reactive data from Meteor’s Collections, this data is received by the component as props. Is some cases, however, this data that comes from the database needs to be modified inside this component and sent back to the database, for that it would be better to have this data in the component’s state. Is it anti-pattern to assign the received props to the component’s state inside a componentWillReceiveProps call?

1 Like

No. I think that’s pretty reasonable!

1 Like

Is it ok to use that approach even when you don’t really need to modify your props? Sometimes it would just be more appropriate to have data in the Component’s state.

Props are the main way components are supposed to receive external input I think.