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

Feat(data-ingestion): Transfer needs assessment data from Gatsby to Strapi #48

Open
1 task
TravisAlmey opened this issue May 16, 2024 · 1 comment · May be fixed by #66
Open
1 task

Feat(data-ingestion): Transfer needs assessment data from Gatsby to Strapi #48

TravisAlmey opened this issue May 16, 2024 · 1 comment · May be fixed by #66
Assignees

Comments

@TravisAlmey
Copy link
Contributor

TravisAlmey commented May 16, 2024

Research approaches to transfer data from Gatsby to Strapi

Possible approaches include:

  • CSV import

  • API endpoints

  • Database import

  • Custom importing scripting

  • Determine and document implentation

@jtfairbank
Copy link
Collaborator

Hey @TravisAlmey I was able to pull the processed needs assessment data out of the current landing site repo pretty easily (see attached here). The trick is:

  1. Modify the sourceNeedsAssessmentData.ts to import writeFileSync at the top, and then add writeFileSync("./needs-data.json", JSON.stringify(needsDatas)) to line 164 right before the for loop that creates the gatsby nodes
  2. Run yarn build to build the site, triggering Gatsby to source / process data for the site which will result in the needs data being written out to a file.

needs-data.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In Progress
3 participants