Skip to content

Conversation

@interim17
Copy link
Contributor

@interim17 interim17 commented Jan 23, 2026

Problem

This is a proof of concept that we can use .gql (graphql) files to build out our schema typing.

Assuming we want to continue to leverage the typing that gatsby provides when it reads our schema and queries, I find the large string literal difficult to read and it lacks IDE support.

Screenshot 2026-01-23 at 3 00 49 PM

The .gql file ont he other hand has syntax highlighting and types can be split up into different files by theme:

Screenshot 2026-01-23 at 3 01 11 PM

The approaches can be blended.

  • New feature (non-breaking change which adds functionality)

} = require("./gatsbyutils/gatsby-resolver-utils");
const { DATASET_PATH } = require("./gatsbyutils/constants");

const read = (p) => fs.readFileSync(path.join(__dirname, p), "utf8");
Copy link
Contributor Author

Choose a reason for hiding this comment

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

real JS devs love vanilla node

@interim17 interim17 requested a review from meganrm January 23, 2026 23:04
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