Repeated buttons from Sheets database

When using sheets as a database with the HTTP request the expectation is that repeated text in a column will be shown once when displayed dynamically in buttons. However this is not the case, the same text will show many times as it appears in rows.
No description
3 Replies
Baptiste
Baptiste12mo ago
That's a good point
Apploader
ApploaderOP12mo ago
Sorted on my side with const provincesArray = {{provinces}}; const cleanedArray = provincesArray.filter(element => element || element === 0); // Convert the array to a Set to remove duplicates const uniqueSet = new Set(cleanedArray); // Convert the Set back to an array const uniqueArray = Array.from(uniqueSet); return uniqueArray; // [1, 2, 3, 4, 5]

Did you find this page helpful?