Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhanced fetching of Definitions via radar-self-enrolment-definitions #15

Conversation

this-Aditya
Copy link
Member

Updated definitions fetching from radar-self-enrolment-definitions instead of fetching locally.

This implementation utilizes data-cache and cached-record to cache content received from GitHub for a specified duration. This approach reduces the need for multiple network calls to the same endpoints, particularly in cases of page refreshes or frequent revisits.

@yatharthranjan @mpgxvii @Bdegraaf1234 , please review this pull request and provide feedback if any improvements are needed.

Fixes: #13

@@ -103,4 +112,21 @@ const EligibilityForm: React.FC<EligibilityFormProps> = ({
</MarginCard>
)

export const getServerSideProps: GetServerSideProps = async (context) => {
const {projectId} = context.query
Copy link
Member Author

@this-Aditya this-Aditya Aug 14, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn't find a way to use sessionStorage in getServerSideProps, so I am also utilizing projectId in both the eligibility and study-consent pages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant