React-redux-firebase: Filter by multiple fields on firestoreConnect

Created on 20 May 2019  路  1Comment  路  Source: prescottprue/react-redux-firebase

Hi, I want to do a filter by multiple fields, something like that:

firestoreConnect(({ location }) => [
  {
    collection: 'students',
    where: ['age', '>=', 12],
    where: ['name', '==', 'Gabe'],
  },
];

Most helpful comment

firestoreConnect(({ location }) => [
  {
    collection: 'students',
    where: [
      ['age', '>=', 12],
      ['name', '==', 'Gabe'],
    ],
  },
];

>All comments

firestoreConnect(({ location }) => [
  {
    collection: 'students',
    where: [
      ['age', '>=', 12],
      ['name', '==', 'Gabe'],
    ],
  },
];
Was this page helpful?
0 / 5 - 0 ratings