#HELP -> Caching problem - still old data

23 messages · Page 1 of 1 (latest)

hard stone
#

Could you show what ur fetch looks like?

waxen sigil
#

After that, I map the array but the displayed data is still old, altough the fetched data is new and different

hard stone
#

do you have any revalidate exported const?

waxen sigil
#

export const revalidate = 60;

#

this is in the file, right after imports

hard stone
#

@waxen sigil do you have the React Dev Tools extension? In order to see if the problem comes from the state or the UI?

waxen sigil
#

Yep, I have it

hard stone
#

(btw because you use it in client side components, the validate const isn't applicable)

waxen sigil
#

Would you be kind enough to take look yourself? I just can't seem to find the **<p>** tag with React dev tools components that display the old information
The website is live in production, easy to inspect

hard stone
#

so if the data is good, it seems you don't rerender the component when it should be

#

how do you display your data?

waxen sigil
#

I figured out a pattern, from all of the data, only the Transactions and Accounts are displayed directly, inside a P tag and are the only ones that are not updated. The rest of the elements are inside another components and seems to be showing correct data. Could this be?

hard stone
#

could you show ur coins state and ur filteredCoins variable?

#

here's the point

#

(I think)

#

You do not update the filteredCoins variable when the state changes

waxen sigil
#

Well, even if i do this
{coins?.map((coin, key) => (
It's the same issue
coins is the state where I save the fetched supabase data

#

fetchCoins().then((data) => setCoins(data))

hard stone
#

do you mind showing your whole component?

waxen sigil
#

Like the whole page? Sure

#

Sorry for buzzing brother, It seems it was from a stupid function that cuts off some decimals

#

thanks alot for your patience