keystonejs / keystone

The superpowered headless CMS for Node.js — built with GraphQL and React
https://keystonejs.com
MIT License
9.18k stars 1.15k forks source link

Fix the type of `id` on type `BaseItem`, to be type `unknown`, not `string` #9054

Open dcousens opened 7 months ago

dcousens commented 7 months ago

This pull request updates the type of id on type BaseItem to be of type unknown instead of string. This helps reduce a number of type errors where string | number | null is possible, but only string was accepted by the BaseItem.

This is not strictly related to https://github.com/keystonejs/keystone/issues/8846, but will likely be required as part of fixing that problem in any event.

codesandbox-ci[bot] commented 7 months ago

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 7956a1b507e7f3945c7289c06ce46eeb96cbd520:

Sandbox Source
@keystone-6/sandbox Configuration