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

Externalize data #34

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

Conversation

conradolandia
Copy link
Collaborator

@conradolandia conradolandia commented Nov 27, 2024

This PR aims to find and externalize all static data on the website so it can be imported from YAML files.

The website now loads its data from 4 sources, depending on the needed data:

  • If we are loading general configuration for the website, it resides now in $lib/config/content.yaml. The file $lib/config/index.js loads data from the YAML source and exports variables accordingly. This preserves compatibility with the previous configuration.
  • Each route has its own YAML data source. So, routes/content.yaml will provide content for the front page, routes/about/content.yaml will provide content for the /about route, and so on. Only the /blog route does not require an external content file.

Copy link

netlify bot commented Nov 27, 2024

Deploy Preview for spyder-website-preview failed.

Name Link
🔨 Latest commit 5dcde4d
🔍 Latest deploy log https://app.netlify.com/sites/spyder-website-preview/deploys/678953303b586000085aa470

@conradolandia conradolandia marked this pull request as ready for review December 5, 2024 22:21
@conradolandia conradolandia self-assigned this Dec 5, 2024
@conradolandia conradolandia added the enhancement New feature or request label Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant