# Research for UniRep User State RPC Response 1. User.tsx await userState.getData() await userState.getProvableData() https://github.com/social-tw/social-tw-website/blob/4951dc4803ccb79df7fdb9ea6e83205310b08c5c/packages/frontend/src/contexts/User.tsx#L156 2. types.ts 3. Userstate.ts genUserStateTransitionProof https://github.com/social-tw/social-tw-website/blob/4951dc4803ccb79df7fdb9ea6e83205310b08c5c/packages/frontend/src/contexts/Userstate.ts#L803 4. useActionCount.ts userState.getEpochKeys() https://github.com/social-tw/social-tw-website/blob/4951dc4803ccb79df7fdb9ea6e83205310b08c5c/packages/frontend/src/hooks/useActionCount.ts#L21 5. useCreateComment.ts, useCreatePost.ts, useDeleteComment.ts, useFetchComment.ts, useSignupWithServer.ts, useSignupWithWallet.ts, useVotes.ts await userState.latestTransitionedEpoch() await userState.sync.calcCurrentEpoch() userState.genEpochKeyProof() await userState.waitForSync() await loadData(userState) https://github.com/social-tw/social-tw-website/blob/main/packages/frontend/src/hooks/useCreateComment.ts 6. useEpoch.ts const _remainingTime = userState.sync.calcEpochRemainingTime() https://github.com/social-tw/social-tw-website/blob/main/packages/frontend/src/hooks/useEpoch.ts 7. (Not Sure) PostDetail.tsx, index.tsx, HomePostForm.tsx useProfileHistoryStore in https://github.com/social-tw/social-tw-website/blob/main/packages/frontend/src/pages/Profile/History/store/useProfileHistoryStore.ts await invokeFetchHistoryCommentsFlow(userState as unknown as UserState) … related stuff https://github.com/social-tw/social-tw-website/blob/main/packages/frontend/src/pages/PostDetail.tsx 8. checkVoteIsMine.ts let userEpochKeys = userState.getEpochKeys(vote.epoch) https://github.com/social-tw/social-tw-website/blob/main/packages/frontend/src/utils/checkVoteIsMine.ts
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up