This is what I got for you:
After you retrieve the data from the Collection you want, you can filter it, anyway you like it, it is going to be just a regular object. Like this:
aimport wixData from "wix-data"
$w.onReady(async () => {
//Stores all services in this variable
const allServices = await getServices()
//Defines repeater as a variable, you can change the element to yours
const repeater = $w("#repeater1")
//Stores feeded initial Repeater Data, its not going to be used again unless page is reloaded
const repeaterData = feedRepeater(repeater, allServices)
//Created a button that filters the Repeater with the word "Velo" as my example collection had a tagLine with that word
$w("#button2").onClick(() => {
let filterRepeaterData = filterDataInRepeater(repeater, "Velo")
let updatedRepeater = feedRepeater(repeater, filterRepeaterData)
})
})
//Gets all services on Bookings Collection
const getServices = async () => {
let results = await wixData.query("Bookings/Services").find()
console.log(results)
return results.items
}
//Feed the data to the repeater
const feedRepeater = (repeater, fillData) => {
repeater.data = fillData
repeater.forEachItem(($item, itemData, index) => {
$item("#textRepeater").text = itemData.tagLine
$item("#textRepeaterTitle").text = itemData.serviceName
})
}
//Filter data in repeater
const filterDataInRepeater = (repeater, filterWord) => {
filterWord = filterWord.toLowerCase()
const filteredData = repeater.data.filter(item => item.tagLine.toLowerCase().includes(filterWord))
return filteredData
}