meilisearch / meilisearch/meilisearch-php
Add types to document handling methods (HandlesDocuments trait)
Open
Beginner friendly
Nobody has claimed this yet.
breaking-change
- Dominant language
- PHP
- Stars
- 757
- Forks
- 125
- Avg merge
- 6d 8h
- Merged PRs (30d)
- 2
Description
The HandlesDocuments trait contains several methods with generic array parameters or missing return types.
File: src/Endpoints/Delegates/HandlesDocuments.php
Action:
getDocument(...): Add PHPDoc@return array<string, mixed>.addDocuments(array $documents, ...): Add PHPDoc@param list<array<string, mixed>> $documents.updateDocuments(array $documents, ...): Add PHPDoc@param list<array<string, mixed>> $documents.deleteDocuments(array $options): Add PHPDoc for expected$optionsshape.addDocumentsInBatches: Add specific array type PHPDoc.updateDocumentsInBatches: Add specific array type PHPDoc.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Open src/Endpoints/Delegates/HandlesDocuments.php and inspect the PHPDoc and signatures for getDocument, addDocuments, updateDocuments, deleteDocuments, addDocumentsInBatches, and updateDocumentsInBatches. Add the requested generic array annotations and the expected options shape for deleteDocuments. The work is done when all six methods have specific, accurate PHPDoc types.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- api
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 62/100