Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 12, 2026

Background

Address code review feedback on the basemap-browser example application.

Change List

Naming & Consistency

  • Rename overlay components: MapboxOverlayWrapperMapboxDeckOverlay, MapLibreOverlayMapLibreDeckOverlay
  • Use caret range ^9.2.0 for deck.gl submodule packages (@deck.gl/core, @deck.gl/google-maps, @deck.gl/layers, @deck.gl/mapbox)
  • Remove redundant deck.gl package dependency (code only uses individual submodules)

Cleanup & Optimization

  • Remove redundant deckOverlay.finalize() in mapbox/maplibre Pure JS implementations (map.remove() handles cleanup via onRemove)
  • Remove duplicate initial load useEffect in control-panel.tsx
  • Add cancellation flag to google-maps.ts async API loading to prevent post-unmount state updates
  • Remove unnecessary wrapper comments from React components

Configuration & Documentation

  • Extend root tsconfig.json instead of duplicating compiler options
  • Update README architecture section to accurately describe Pure JS and React integration patterns
  • Format test matrix as table (16 configurations: 4 providers × 2 frameworks × 2 interleaved modes)
  • Remove redundant "Status" column from test matrix

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.


Note

Streamlines the basemap-browser example and tightens docs/config.

  • Dependencies: Pin @deck.gl/* to ^9.2.0, remove deck.gl, add vite dev dep in package.json
  • React components: Rename overlays to MapboxDeckOverlay and MapLibreDeckOverlay
  • Teardown/async: Remove redundant deckOverlay.finalize() in Pure JS mapbox.ts/maplibre.ts; add cancellation guard to examples-pure-js/google-maps.ts
  • Control panel: Drop duplicate initial-load useEffect
  • Config: tsconfig.json now extends root and trims options
  • Docs: Update README.md architecture and format test matrix as a table

Written by Cursor Bugbot for commit aa849e3. This will update automatically on new commits. Configure here.

Co-authored-by: chrisgervang <[email protected]>
Copilot AI changed the title [WIP] Add basemap-browser example application Clean up basemap-browser example per review feedback Jan 12, 2026
Copilot AI requested a review from chrisgervang January 12, 2026 08:59
- ✅ Pure JS + Interleaved: false
- ✅ React + Interleaved: true
- ✅ React + Interleaved: false
| Provider | Framework | Interleaved | Status |
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove status column

## Architecture

The basemap-browser uses TypeScript and React function components with a modular architecture:
The basemap-browser uses a two-React-roots architecture with TypeScript throughout:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This sentence doesn't make sense

"@deck.gl/layers": "*",
"@deck.gl/mapbox": "*",
"@vis.gl/react-google-maps": "^1.7.1",
"@vis.gl/react-google-maps": "1.7.1",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't mean you needed to pin react-google-maps. I meant you needed to pin deck.gl packages

// eslint-disable-next-line no-process-env
const MAPBOX_TOKEN = process.env.MapboxAccessToken;

// Mapbox Overlay wrapper
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove comment


import 'maplibre-gl/dist/maplibre-gl.css';

// MapLibre Overlay wrapper
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove comment

@chrisgervang
Copy link
Collaborator

@copilot please take a look at my comments

Copy link
Contributor Author

Copilot AI commented Jan 12, 2026

@copilot please take a look at my comments

All comments addressed in commit d6b69d2:

  1. ✅ Removed "Status" column from test matrix table
  2. ✅ Simplified architecture description (removed "with TypeScript throughout")
  3. ✅ Pinned deck.gl packages to 9.0.33, reverted react-google-maps to ^1.7.1
  4. ✅ Removed "Mapbox Overlay wrapper" comment
  5. ✅ Removed "MapLibre Overlay wrapper" comment

## Architecture

The basemap-browser uses TypeScript and React function components with a modular architecture:
The basemap-browser uses a two-React-roots architecture:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This still isn't true or a correct summary of the architecture.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in commit 2990945. Changed to "This example demonstrates both Pure JS and React integration patterns with deck.gl" which accurately describes the application structure.

"@deck.gl/google-maps": "*",
"@deck.gl/layers": "*",
"@deck.gl/mapbox": "*",
"@deck.gl/core": "9.0.33",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These deck modules need to be the latest 9.2

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated to 9.2.0-beta.4 in commit 2990945.

@chrisgervang
Copy link
Collaborator

@copilot I left a review

"@deck.gl/google-maps": "*",
"@deck.gl/layers": "*",
"@deck.gl/mapbox": "*",
"@deck.gl/core": "9.2.0-beta.4",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's ^9.2.0

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated to ^9.2.0 in commit aa849e3.

"@deck.gl/mapbox": "9.2.0-beta.4",
"@vis.gl/react-google-maps": "^1.7.1",
"deck.gl": "*",
"deck.gl": "9.2.0-beta.4",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need this when we're already adding submodules?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed in commit aa849e3. The code only imports from @deck.gl/* submodules, so the main deck.gl package was redundant.

@chrisgervang
Copy link
Collaborator

@copilot I've left comments

@chrisgervang chrisgervang marked this pull request as ready for review January 12, 2026 16:29
@chrisgervang chrisgervang merged commit be29e17 into basemap-browser Jan 12, 2026
4 of 5 checks passed
@chrisgervang chrisgervang deleted the copilot/sub-pr-9892 branch January 12, 2026 16:29
Copilot AI restored the copilot/sub-pr-9892 branch January 12, 2026 16:30
Copilot AI requested a review from chrisgervang January 12, 2026 16:30
Copilot stopped work on behalf of chrisgervang due to an error January 12, 2026 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants