Skip to content

docs: fix incorrect select syntax example in querying docs#14590

Merged
paulpopus merged 2 commits into
payloadcms:mainfrom
syazwanz:docs/fix-select-array-example
Apr 9, 2026
Merged

docs: fix incorrect select syntax example in querying docs#14590
paulpopus merged 2 commits into
payloadcms:mainfrom
syazwanz:docs/fix-select-array-example

Conversation

@syazwanz

Copy link
Copy Markdown
Contributor

What?

Fix incorrect select example in the querying docs. The docs showed select: [{ title: true }] which is not valid. Updated to select: { title: true } to match actual API usage and TypeScript types.

Why?

The wrong example causes TypeScript errors and confusion for users. Correcting it makes the docs accurate and consistent.

How?

Updated the example in docs/queries/overview.mdx to use object syntax for select. No code changes, documentation only.

@syazwanz

Copy link
Copy Markdown
Contributor Author

Hi, just checking if this PR can be reviewed. Thanks.

@AlessioGr AlessioGr left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thank you!

@AlessioGr AlessioGr enabled auto-merge (squash) January 10, 2026 04:03
@github-actions github-actions Bot added the stale label Feb 20, 2026
@paulpopus paulpopus disabled auto-merge April 9, 2026 12:04
@paulpopus paulpopus merged commit be6c443 into payloadcms:main Apr 9, 2026
16 checks passed
@github-actions

github-actions Bot commented Apr 9, 2026

Copy link
Copy Markdown
Contributor

🚀 This is included in version v3.82.1

milamer pushed a commit to milamer/payload that referenced this pull request Apr 20, 2026
…s#14590)

### What?

Fix incorrect select example in the querying docs. The docs showed
`select: [{ title: true }]` which is not valid. Updated to `select: {
title: true }` to match actual API usage and TypeScript types.

### Why?

The wrong example causes TypeScript errors and confusion for users.
Correcting it makes the docs accurate and consistent.

### How?

Updated the example in docs/queries/overview.mdx to use object syntax
for select. No code changes, documentation only.

Co-authored-by: Paul Popus <paul@payloadcms.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants