Imagine having a string formatted like this:
const name = "Matt"
Now, you want to transform it into an array like the following:
nameSearchArr = [
0: "M",
1: 'Ma',
2: 'Mat',
3: 'Matt
]
To work around Firestore's lack of 'full text search' functionality, I am looking to create an array and utilize 'array-contains' for searching names. This way, while typing in a name, it will match with the elements in the nameSearchArr. Does anyone have recommendations on the best approach to achieve this? Thank you in advance!