viewState `padding` expected to be optional
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 8.5k
- Forks
- 1.4k
- Avg merge
- 5d 17h
- Merged PRs (30d)
- 3
Description
Currently I'm experiencing a Property 'padding' is missing in type ... but required in type 'ViewState'. error. I'd expect this type to be optional based on this implementation:
https://github.com/visgl/react-map-gl/blob/109c334bdffaa5b2016c50bf6aaa119ce56082ce/src/mapbox/mapbox.ts#L544-L546
I believe the issue is in this type definition, which should define padding as optional.
I can open a PR to fix this if it should be optional.
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 by comparing the ViewState definition in src/types/external.ts with the implementation around src/mapbox/mapbox.ts:544-546. Confirm that the implementation permits missing padding, then update the type so it matches that behavior; the issue is done when the reported TypeScript error no longer occurs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 38/100