KnpLabs / KnpLabs/knp-components

Add generic to PaginatorInterface

Open Beginner friendly
#351 0 comments 0 reactions 0 assignees View on GitHub
RFC
Dominant language
PHP
Stars
773
Forks
139
Avg merge
22h 3m
Merged PRs (30d)
1

Description

I'm wondering if we could improve PaginatorInterface, which currently has a `@return PaginationInterface`

We could add `@template T of mixed` in the interface phpdoc, and replace the "mixed" above with "T"

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at PaginatorInterface and read its existing PHPDoc, especially the PaginationInterface return annotation. Define the generic type in the interface and use it in that return annotation, then verify that the interface documentation expresses the paginator item type without changing runtime behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Refactor
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.