2

I am using react-redux-firestore v2.4 The error below happens What is "storeAs"? I would like to use subcollentions in this version.

https://react-redux-firebase.com/docs/firestore but this version is not support "storeAs".

Queries with subcollections must use "storeAs" to prevent invalid store updates. This closley matches the upcoming major release (v1), which stores subcollections at the top level by default. console. @ index.js:1


render()
{
return
<div>
subs = {project.subprojects?.content}
</div>
}
export default compose(
  connect(mapStateToProps),
  firestoreConnect((props) => [
    { collection: "projects" },
    {
      collection: "projects",
      doc: props.match.params.id,
      subcollections: [{ collection: "subprojects" }]
    },
  ])
)(ProjectDetails);
user14232549
  • 405
  • 4
  • 17

0 Answers0