Install
openclaw skills install @binggg/web-developmentUse when users need to implement, integrate, debug, build, deploy, or validate a Web frontend after the product direction is already clear, especially for React, Vue, Vite, browser flows, or CloudBase Web integration.
openclaw skills install @binggg/web-developmentIf this environment only installed the current skill, start from the CloudBase main entry and use the published cloudbase/references/... paths for sibling skills.
https://cnb.cool/tencent/cloud/cloudbase/cloudbase-skills/-/git/raw/main/skills/cloudbase/SKILL.mdhttps://cnb.cool/tencent/cloud/cloudbase/cloudbase-skills/-/git/raw/main/skills/cloudbase/references/web-development/SKILL.mdKeep local references/... paths for files that ship with the current skill directory. When this file points to a sibling skill such as auth-tool or web-development, use the standalone fallback URL shown next to that reference.
Cross-cutting protocols (required before code changes or static hosting publish):
https://cnb.cool/tencent/cloud/cloudbase/cloudbase-skills/-/git/raw/main/skills/cloudbase/references/cloudbase-platform/references/protocols/change-safety-protocol.mdhttps://cnb.cool/tencent/cloud/cloudbase/cloudbase-skills/-/git/raw/main/skills/cloudbase/references/cloudbase-platform/references/protocols/deployment-gate.mdui-design first.ui-design skill and output a Design Specification. Skipping this step causes frontend styling to degrade to generic AI template defaults. The ui-design skill must be loaded before any visual implementation begins, not retroactively after the user complains about the appearance.frameworks.mdbrowser-testing.md../auth-tool/SKILL.md (standalone fallback: https://cnb.cool/tencent/cloud/cloudbase/cloudbase-skills/-/git/raw/main/skills/cloudbase/references/auth-tool/SKILL.md), then ../auth-web/SKILL.md (standalone fallback: https://cnb.cool/tencent/cloud/cloudbase/cloudbase-skills/-/git/raw/main/skills/cloudbase/references/auth-web/SKILL.md)../cloudbase-wechat-integration/SKILL.md (standalone fallback: https://cnb.cool/tencent/cloud/cloudbase/cloudbase-skills/-/git/raw/main/skills/cloudbase/references/cloudbase-wechat-integration/SKILL.md; official docs: https://docs.cloudbase.net/integration/introduce/index.md)cloudbase-wechat-integration after identifying the Web surface.index.html. This causes NoSuchKey / 404 errors when users refresh or directly visit any sub-route.These rules override convenience. Treat them as a gate before saying "done".
any to bypass type errors. Not : any, not as any, not @ts-ignore, not @ts-nocheck, not @ts-expect-error without a written justification. any propagates silently and defeats the only compile-time safety net this project has.@types/..., or narrow the import, or write a precise interface / type for the shape you actually use.postMessage payload, window.* injection) → type it as unknown and narrow with a type guard (typeof, in, a discriminator field, or zod / equivalent).declare module in a local .d.ts, not any.<T> with a constraint, not any.unknown + narrowing is the acceptable escape hatch. any is not.any for a specific line (extremely rare), leave a one-line comment with why and what would remove it, so reviewers can audit.// eslint-disable to mute the real signal. Fix the rule violation, or discuss before disabling.Before making any non-trivial code or configuration change, you must first follow the Change Safety Protocol in cloudbase-platform/references/protocols/change-safety-protocol.md (declare impact → user confirmation → post-edit verification).
Before any static hosting publish or custom domain work, complete the checks in cloudbase-platform/references/protocols/deployment-gate.md.
Saying "I've implemented it" / "fixed it" / "it should work" without evidence is not acceptable. Before declaring completion, you must actually run the checks and report the result.
Static / build layer (always, when applicable):
tsc --noEmit (or vue-tsc --noEmit) passes cleanly — zero errors, zero suppressed diagnostics you added.eslint / project linter passes on changed files.npm run build / pnpm build / vite build) completes without new warnings that you introduced.Runtime / browser layer (whenever the change affects rendering, routing, forms, auth, or async flows):
agent-browser tool to actually open the page and reproduce the user-visible flow. Follow browser-testing.md for the concrete workflow.Only after both layers pass may you say the task is done. If either layer cannot be executed locally (e.g. blocked by credentials, missing backend, paid API), say so explicitly and list exactly which step is still unverified — do not gloss over it.
try { ... } catch {} to make the error go away.Use this skill for Web engineering work such as:
Do NOT use for:
ui-designminiprogram-developmentcloudrun-development or cloud-functionsClarify the execution surface
Follow framework and build conventions
src and build output under dist unless the repo already uses a different convention.src/lib/backend.*, src/lib/auth.*, src/lib/*service.*, route guards, and the page handlers bound to submit buttons.Validate through the browser, not only by reading code
agent-browser workflows from browser-testing.md.Treat CloudBase as an integration branch
auth-tool and auth-web for login or provider readiness instead of re-describing those flows here.tsc --noEmit and a clean project build are the minimum bar — not proof of correctness.agent-browser. Code reading alone is not sufficient evidence — see the Engineering constitution above.Use this section only when the Web project needs CloudBase platform features.
app or auth instance instead of re-initializing on every callEnvId before writing SDK init code, console links, or config files. Do not pass alias-like short forms directly into cloudbase.init({ env }).auth-tool and auth-webBuild before deployment
Prefer relative asset paths for static hosting compatibility
Use hash routing by default when the project lacks server-side route rewrites
If the user does not specify a root path, avoid deploying directly to the site root by default
SPA routing (History mode): when using React Router / Vue Router in History mode (not hash mode), configure the CloudBase static hosting "404 error document" to index.html. Otherwise refreshing or directly visiting any sub-route returns NoSuchKey / 404 error, because the static hosting looks for a file at that path instead of falling through to index.html for the SPA to handle routing.
Use the MCP tool to apply this:
manageHosting({ action: "setWebsiteDocument", indexDocument: "index.html", errorDocument: "index.html" })
Then verify with:
queryHosting({ action: "websiteConfig" })
// npm install @cloudbase/js-sdk
import cloudbase from "@cloudbase/js-sdk";
const app = cloudbase.init({
env: "your-full-env-id", // Canonical full CloudBase environment ID resolved from envQuery or the console
});
const auth = app.auth