Unspecified behaviour when `cellSide` does not fit the specified grid in `squareGrid`
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 10.5k
- Forks
- 1k
- Avg merge
- 1h 11m
- Merged PRs (30d)
- 4
Description
Refer this line: https://github.com/Turfjs/turf/blob/b6cb691e0d23293ca0c881fe561f0e8a4536ad6a/packages/turf-rectangle-grid/index.js#L48
The documentation does not clarify how squareGrid behaves in the following case: cellSide does not fit in the specified bbox.
The referred line above suggests that the grid would be centered in the bbox to ensure that it is completely inside it. However, #444 suggests that it may overflow the bbox.
Question: What does Turf (intend to) do when such a scenario occurs?
Suggestion: The behavior must be specified in the documentation.
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 at packages/turf-rectangle-grid/index.js line 48 and compare its behavior with the concern raised in #444. Confirm with maintainers whether squareGrid should stay within the bbox or overflow when cellSide does not fit, then document the decided behavior in the relevant documentation. Done means the edge case and resulting grid placement are explicitly described.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100