Sitelet https://github.com/rnmapbox/maps/pull/4313
Skip to content

feat(web): generate layer style property table from the style spec - #4313

Merged
mfazekas merged 1 commit into
mainfrom
claude/project-thread-xjrh7o
Oct 5, 2026
Merged

mfazekas merged 1 commit into
mainfrom
claude/project-thread-xjrh7o

Conversation

@mfazekas

@mfazekas mfazekas commented Oct 4, 2026 •

Copy link
Copy Markdown
Contributor

Description

Before: web layers used a hand-written list of layout props and treated every other prop as paint, so props like iconImage or textField were sent as paint.

After: yarn generate writes src/web/utils/webStyleMap.ts from the style spec, and web layers look up each prop's spec name and kind (paint or layout) there. Unknown props are warned about and skipped.

  • New template scripts/templates/webStyleMap.ts.ejs, in the same pass as styleMap.ts.
  • toGLStyle uses the generated table; *Transition props still map to <name>-transition.

Checklist

  • I updated the doc/other generated code with running yarn generate in the root folder
  • I have tested the new feature on /example app (web, Chromium): circle and line layers with lineCap, a color transition and a style switch render with no warnings.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SY4pX3Uqk9xHo6LK9svAjV
@mfazekas mfazekas self-assigned this Oct 4, 2026
@mfazekas
mfazekas merged commit e0949ad into main Oct 5, 2026
6 checks passed
@mfazekas
mfazekas deleted the claude/project-thread-xjrh7o branch October 5, 2026 02:17

This branch was successfully deployed

1 active deployment
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.

1 participant