web-development

Structure and deploy web frontend projects with CloudBase Web SDK integration.

72|5|Updated Jan 22, 2026
One-click install
npx skills add https://github.com/TencentCloudBase/skills --skill web-development-tencentcloudbase
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: web-development
Source: https://github.com/TencentCloudBase/skills/tree/main/skills/web-development
Command: npx skills add https://github.com/TencentCloudBase/skills --skill web-development-tencentcloudbase

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill provides a structured approach to building, hosting, and integrating web frontend projects with the CloudBase Web SDK, reducing setup ambiguity and guiding best practices.

Core Features & Use Cases

  • Project Structure: Frontend source code in src, build output in dist, and CloudBase cloud functions in cloudfunctions.
  • CloudBase Web SDK Integration: Use SDK for authentication, database, hosting, and environment ID queries via envQuery.
  • Deployment & Routing: Promote hash routing for static hosting and configure deployment steps for CloudBase static hosting.

Quick Start

Apply this skill to a frontend project by ensuring the directories src, dist, and optionally cloudfunctions exist, install dependencies with npm install, configure publicPath for static hosting, enable hash routing, and deploy to CloudBase static hosting.

Frequently Asked Questions about web-development

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What is the best way to deploy a Vite or Webpack frontend to static hosting?

Deploying a Vite or Webpack frontend to static hosting requires structuring the project with a dist output directory, configuring publicPath, enabling hash routing, and uploading the build to CloudBase static hosting.

How do I integrate the CloudBase Web SDK for authentication and database operations?

Integrating the CloudBase Web SDK for authentication and database operations involves installing the SDK via npm install, initializing it with your environment ID, and calling its APIs to manage user auth and data queries.

Why should I use hash routing for static hosting deployments?

Using hash routing for static hosting deployments prevents broken paths during page refreshes or direct URL access, because the hosting server always serves the single entry point file without needing complex server-side rewrite rules.

Do I need a specific project structure to use CloudBase Web SDK?

You need a specific project structure to use CloudBase Web SDK that separates frontend source code in the src directory, build output in the dist directory, and CloudBase cloud functions in a cloudfunctions directory.

How do I query environment ID for my web app using CloudBase?

To query the environment ID for your web app using CloudBase, use the envQuery function provided by the CloudBase Web SDK after installing dependencies and initializing the client.

Does CloudBase static hosting work with modern frontend tooling like Vite?

CloudBase static hosting works with modern frontend tooling like Vite or Webpack by configuring the build output directory and publicPath correctly, enabling seamless deployment of modern web apps.