返回顶部
m

mapbox

Build, debug, and integrate Mapbox apps and APIs, including Mapbox GL JS map setup, styles, sources/layers, markers/popups, geocoding, directions, static images, and token-safe frontend patterns. Use when the user asks for Mapbox code, Mapbox architecture, style expressions, tile/source issues, or Mapbox migration guidance. 中文触发:Mapbox、地图样式、矢量瓦片、地理编码、路径规划、底图集成。

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
111
下载量
1
收藏
概述
安装方式
版本历史

mapbox

# Mapbox Use this skill for practical Mapbox platform work in web apps and API integrations. ## Workflow 1. Confirm the runtime first: plain HTML, Vite, React, Next.js, or another framework. 2. Confirm which Mapbox surface is involved: GL JS map rendering, styles, tilesets, geocoding, directions, or static images. 3. Start with the smallest working map before adding custom sources, layers, controls, or API calls. 4. Keep access tokens out of source files and examples unless the user explicitly wants a local-only demo. 5. For bugs, isolate whether the failure is in container sizing, token/scopes, style/source IDs, coordinate order, or layer order. ## Implementation Guardrails - Prefer `mapbox-gl` with explicit imports and explicit CSS loading. - Always ensure the map container has a real height before debugging rendering. - Use `lng, lat` order consistently for Mapbox coordinate arrays. - Add sources before layers, and keep layer IDs stable so updates are easy. - Prefer GeoJSON for lightweight overlays; move to vector tiles or tilesets for larger datasets. - In React or other SPA frameworks, remove the map instance during teardown to avoid leaks. - Treat the access token as configuration. Read it from environment or runtime config instead of hardcoding it. ## Common Failure Checks - Blank map: verify token, style URL, CSS import, and container height. - Layer not visible: verify source exists, source-layer matches, zoom bounds, and paint/layout visibility. - Wrong location: verify coordinate order and CRS assumptions; Mapbox expects WGS84 `lng,lat`. - Performance issues: reduce marker count, cluster point data, and prefer data-driven layers over many DOM markers. - API failures: verify token scopes, endpoint type, rate limits, and request parameters. ## Task Boundaries - Use this skill for Mapbox-specific implementation, debugging, and integration patterns. - For generic CRS/projection reasoning, use `project` or `wgs84`. - For deterministic desktop GIS batch processing, use `qgis`. - For CesiumJS globe rendering, use `cesium`. ## OpenClaw + ClawHub Notes - Keep examples generic, portable, and token-safe. - Do not hardcode private datasets, private style URLs, or machine-specific paths. - For clawhub.ai publication, keep content reproducible and semver-friendly; put detailed examples in references instead of bloating `SKILL.md`. ## Reference Docs In This Skill - Read `{baseDir}/references/patterns.md` when generating or fixing Mapbox GL JS or API integration code.

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 mapbox-1775997382 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 mapbox-1775997382 技能

通过命令行安装

skillhub install mapbox-1775997382

下载 Zip 包

⬇ 下载 mapbox v1.0.0

文件大小: 4.47 KB | 发布时间: 2026-4-13 10:56

v1.0.0 最新 2026-4-13 10:56
- Initial release of the Mapbox skill for building, debugging, and integrating Mapbox apps and APIs.
- Supports Mapbox GL JS setup, styles, sources/layers, geocoding, directions, static images, and token-safe frontend patterns.
- Provides troubleshooting guidance for common Mapbox issues and best practices for integration.
- Includes implementation guardrails and task boundaries for efficient and secure usage.
- 中文触发:支持中文环境下的Mapbox相关问题和指导。

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部