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

Use directus for project fetch #128

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

rodrigonf17
Copy link
Collaborator

No description provided.

Copy link

vercel bot commented Sep 13, 2024

Someone is attempting to deploy this pull request to the gainforest Team on Vercel.

To accomplish this, the commit author's email address needs to be associated with a GitHub account.

Learn more about how to change the commit author information.

@daviddao daviddao changed the title test Use directus for project fetch Sep 16, 2024
…oject info tab on project card piece by piece, at least the project card box did not broke as a whole, only the project info until now
Copy link

vercel bot commented Sep 17, 2024

@rodrigonf17 is attempting to deploy a commit to the gainforest Team on Vercel.

To accomplish this, @rodrigonf17 needs to request access to the Team.

Afterwards, an owner of the Team is required to accept their membership request.

If you're already a member of the respective Vercel Team, make sure that your Personal Vercel Account is connected to your GitHub account.

…ter, projectcard had to point the array of resultfetch on activeProjectdata.project[0], found a bug on xprize rainforest entry, the rest is working
console.log(result)
console.log(result.name)
console.log(result[0])
console.log(response)
Copy link
Member

Choose a reason for hiding this comment

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

Please make sure to remove all console.logs from the final result!

return result.data
})

return response
}
//
Copy link
Member

Choose a reason for hiding this comment

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

Same here for the comments

const area = Math.round(activeProjectData?.project?.area / 10000)
const country = countryToEmoji[activeProjectData?.project?.country]
const area = Math.round(activeProjectData?.project[0].area / 10000)
const country = countryToEmoji[activeProjectData?.project[0].country]
Copy link
Member

Choose a reason for hiding this comment

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

Since we have to access the data in this format multiple times (activeProjectData?.project[0]), how can we make this code easier to read? Can we just pass in activeProjectData?.project[0] directly to the function?

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.

2 participants