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

135
Views
Why is an Array seen as Object in React Native?

I know this questions has been asked quite some time now, but this behavior is really weird.

I have an Array of Objects (fetched from my Realm Database) with the following structure:

userDates = [{aT: [array], id: "..", ...}, {aT: [array], id: "..", ...}, ...]

I want to filter this array like the following:

const filtered = userDates.filter(x => x.aT.includes("2022-03-01"))

It says "x.aT.includes is not a function". If I run this:

const filtered = userDates.filter(x => console.log(x.aT))

it will print out:

["2022-03-01", "2022-03-02","2022-03-03"]
["2022-03-13", "2022-03-14","2022-03-15", "2022-03-16"]
["2022-04-01", "2022-04-02","2022-04-03"]

"typeof" says: "object" and "Array.isArray" says "false". I'm confused. x.aT is obviously an array.

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!