Change the default field resolver
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 3.5k
- Forks
- 468
- Avg merge
- 3h 9m
- Merged PRs (30d)
- 2
Description
What problem does this feature proposal attempt to solve?
Community feedback has shown that the default resolver from webonyx/graphql-php may not be optimally suited for a Laravel application and there is potential for improvement.
- Model accessors are called twice
- snake_case vs. camelCase
- https://github.com/nuwave/lighthouse/issues/2687
Because the default resolver is called very often, we have to consider performance.
Which possible solutions should be considered?
Given Eloquent models are probably the most common returned data type, we could optimize for them.
Changing the default resolver is documented here, but could perhaps be simplified through the config.
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
Start with the documented “changing the default resolver” extension point and review the referenced issues about Eloquent accessors, naming, and resolver behavior. The work is not yet defined: done would require an agreed resolver design that addresses the stated Laravel and performance concerns.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- graphql, laravel, php
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100