Skip to content

slugs for foreign keys#33

Open
interim17 wants to merge 13 commits intomainfrom
feature/fk
Open

slugs for foreign keys#33
interim17 wants to merge 13 commits intomainfrom
feature/fk

Conversation

@interim17
Copy link
Contributor

Problem

Advances #27 and #7 Closes #18

Solution

Ongoing work on schema typing, resolvers, and relationships between entities in gatsby's data layer.

The focus of this pr is making this work:
dataset: MarkdownRemark @link(by: "fields.slug")

The idea is to have a foreign key relationship where one markdown file references another by its slug.

This takes a little bit more work than using the raw string from frontmatter.name but it makes the relationships less brittle. Because the slugs are /directory/filename they are far less likely to run into namespace collisions than a field line name.

Attendant to this I added:

  • slugify as a dependency to help with slugs
  • resolver utils for slugs and software entities
  • vitest and one test suit for the resolver utils
  • New feature (non-breaking change which adds functionality)

@interim17 interim17 changed the title Feature/fk slugs for foreign keys Jan 23, 2026
@meganrm
Copy link
Collaborator

meganrm commented Jan 26, 2026

do you need this to branch from your previous work? It's just nice to get the build preview, which happens for PRs against main, and this doesn't seem related to the tag popover

Base automatically changed from feature/tag-popover to main January 29, 2026 20:53
@netlify
Copy link

netlify bot commented Feb 3, 2026

Deploy Preview for project-idea-board ready!

Name Link
🔨 Latest commit da2a471
🔍 Latest deploy log https://app.netlify.com/projects/project-idea-board/deploys/6982a20df2d285000844ef36
😎 Deploy Preview https://deploy-preview-33--project-idea-board.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@interim17
Copy link
Contributor Author

We were running Node 18 in the netlify config and vitest was failing to install, bumping to the version we use in Cell Catalog resolved it

software:
- softwareTool: Simularium
customDescription: CUSTOM DESCRIPTION Used to visualize 3D trajectories and other cool stuff.
customDescription: Custom description in the markdown file for the idea, not in the software file markdown.
Copy link
Collaborator

Choose a reason for hiding this comment

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

we talked about this. I'm skeptical of including this but it's fine for now

Copy link
Contributor

@jessicasyu jessicasyu left a comment

Choose a reason for hiding this comment

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

Read through the tests and they make sense to me!

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.

Use markdown for stable references to software tools

3 participants