Amplify datastore deleting specific list of data

0

My app is a social media clone app. I want a logic like below for my home feed:

amplify api will fetch list of 10 items through pagination -> this 10 items will be showing up to user in feed -> when user reaches the 7th item on the screen I will fetch again 10 items through api call and save it to local datastore-> when user will reach the end item/10th item i will show the next 10 items present in local datastore and I will clear that 10 items in local storage-> and fetch next 10 items-> if user closes app immediately the 10 items will be there in local storage-> next time when user will open app I will show the data without buffer form local storage

My issue is how if user likes a post or makes a comment I will save that to data store for short time and when sync event occurs I will update that like and comment to DynamoDB.

1. My question is how to delete some specific data when some event occurs like list of post?

2. Can we upload new post from datastore? how?

답변 없음

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠