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

Ssgc updates #5667

Merged
merged 3 commits into from
May 11, 2021
Merged

Ssgc updates #5667

merged 3 commits into from
May 11, 2021

Conversation

timleslie
Copy link
Contributor

Update the server-side-graphql-library to use the updated GraphQL APIs, unblocking tests which use this API indirectly via the items API.

@changeset-bot
Copy link

changeset-bot bot commented May 11, 2021

⚠️ No Changeset found

Latest commit: 2addcd8

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link

vercel bot commented May 11, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/keystonejs/keystone-next-docs/14qMzL8y8g2WWfT56w51wFpBzEbB
✅ Preview: https://keystone-next-docs-git-ssgc-updates-keystonejs.vercel.app

@timleslie timleslie changed the base branch from master to next-fields May 11, 2021 02:17
@timleslie timleslie requested a review from emmatown May 11, 2021 02:17
Copy link
Member

@emmatown emmatown left a comment

Choose a reason for hiding this comment

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

just FYI, I haven't made all the GraphQL API changes that we discussed so this will need more changing in the future

@@ -119,7 +119,7 @@ const getItems = async ({
}: {
listKey: string;
where?: Record<string, any> | null;
sortBy?: readonly string[] | null;
orderBy?: readonly Record<string, 'asc' | 'desc'>[] | null;
Copy link
Member

@emmatown emmatown May 11, 2021

Choose a reason for hiding this comment

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

This isn't right, the value can be anything, it will often be asc or desc but that is not guaranteed and there are definitely things that will deviate from it (e.g. relations, fields with multiple fields in the db)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, interesting, what's the correct type here then, is it string, or any?

Copy link
Member

Choose a reason for hiding this comment

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

any

Copy link
Contributor Author

Choose a reason for hiding this comment

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

just FYI, I haven't made all the GraphQL API changes that we discussed so this will need more changing in the future

Yep, just want to get this close enough to run for now 👍

@@ -9,8 +9,7 @@ export type BaseGeneratedListTypes = {
readonly search?: string | null;
readonly first?: number | null;
readonly skip?: number | null;
readonly orderBy?: string;
readonly sortBy?: ReadonlyArray<string> | null;
readonly orderBy?: ReadonlyArray<Record<string, 'asc' | 'desc'>> | null;
Copy link
Member

Choose a reason for hiding this comment

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

Same as above

Copy link
Member

@emmatown emmatown left a comment

Choose a reason for hiding this comment

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

clicked the wrong button

@vercel vercel bot temporarily deployed to Preview May 11, 2021 02:20 Inactive
@vercel vercel bot temporarily deployed to Preview May 11, 2021 02:32 Inactive
@timleslie timleslie requested a review from emmatown May 11, 2021 02:33
@timleslie timleslie merged commit e6fc7d8 into next-fields May 11, 2021
@timleslie timleslie deleted the ssgc-updates branch May 11, 2021 02:37
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