Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

250
Views
"Uncaught Error: Query(...): Nothing was returned from render" error appears while using apollo client`s Query tag in react app

While using apollo in react app, an error appeared and I can't resolve it. I'm trying mapping array in Query tag and after some conditions, render the component.

  render() {
    return (
      <div>
        <h1></h1>
        <div>
          <Query query={PRODUCTS}>
            {({ data, loading }) => {
              if (loading) return "...Loading";
              const { categories } = data;
              console.log(categories);
              if (categories.some((category) => category.name === "all")) {
                const itemIndex = categories.findIndex(
                  (category) => category.name === "all"
                );
                categories[itemIndex].products.map((product) => {
                  console.log(categories[itemIndex].products);
                  return <Card data={product} />;
                });
              }
            }}
          </Query>
        </div>
      </div>
    );
  }
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!