Skip to content

Add ArticleQuery chainable builder#886

Draft
jpurnell wants to merge 1 commit into
twostraws:mainfrom
jpurnell:feature/article-query
Draft

Add ArticleQuery chainable builder#886
jpurnell wants to merge 1 commit into
twostraws:mainfrom
jpurnell:feature/article-query

Conversation

@jpurnell
Copy link
Copy Markdown
Contributor

@jpurnell jpurnell commented May 21, 2026

Summary

  • Adds ArticleQuery fluent builder for filtering, sorting, and paginating [Article] arrays
  • Supports tag filtering (single/anyOf/allOf), author and published filters, date range queries, custom predicates, metadata matching
  • Sorting by date or title with forward/reverse order
  • Limit, offset, and page-based pagination with totalCount
  • 24 new tests covering all query operations and chaining

Design

Purely additive — two new files. Operates on [Article] directly without requiring ArticleIndex or environment modifications. Uses enum-based filters internally for Sendable compliance.

Test plan

  • All 24 new tests pass
  • Full test suite passes (1353 tests)
  • swift build clean with no warnings

Introduces a fluent query API for filtering, sorting, and paginating
Article arrays. Supports tag filtering (single/anyOf/allOf), author
and published filters, date range queries, custom predicates,
metadata matching, sorting by date or title, and limit/offset/page
pagination with totalCount.

Purely additive. ArticleIndex environment integration is planned
as a follow-up.
@jpurnell jpurnell marked this pull request as draft May 21, 2026 22:15
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.

1 participant