Nuxt Plugins
Tencent CloudBase Framework Nuxt SSR Plugin
CloudBase Framework "Nuxt SSR" Plugin: Deploy Nuxt SSR applications to the CloudBase environment with one click via the CloudBase Framework, delivering a high-performance Node SSR application service featuring automatic elastic scaling. It integrates seamlessly with other plugins such as the Website plugin and Function plugin to enable cloud-native integrated development.
Features
- Free from concerns about the underlying architecture: Just focus on developing business services without adapting to functions or containers
- Cost Savings: Achieves significant resource cost reduction through resource scaling, elastic scaling, and flexible billing.
- Framework Support: Seamlessly supports projects built with the Nuxt framework.
Usage
Step 1. Preparations
Specific steps please refer to Preparing the Cloud Development Environment and CloudBase CLI Command Tool
Step 2. Enter the Nuxt project directory and initialize
If you have an existing Nuxt application project
cloudbase
If you want to start a new project from scratch, you can directly execute init to begin a project from a template.
cloudbase init
Step 3. One-Click Deployment
cloudbase framework deploy
Configuration
By default, no configuration is required for use. The following configuration parameters are intended for scenarios with specific requirements.
Configuration Example
After running
cloudbase init, the Cloud Development configuration file
cloudbaserc.js` will be created. You can write plugin configurations in the plugins section of the configuration file.
{
"envId": "{{envId}}",
"framework": {
"plugins": {
"client": {
"use": "@cloudbase/framework-plugin-nuxt",
"inputs": {
"entry": "./",
"path": "/nuxt-ssr",
"name": "nuxt-ssr",
"installCommand": "npm install",
"buildCommand": "npm run build"
}
}
}
}
}
entry
Default ./
The directory of the Nuxt configuration file, by default the current project directory.
path
Access the subpath, such as /nuxt-ssr
name
Service name, such as nuxt-ssr
installCommand
Installation command, such as npm install
, can be omitted if not required.
Default value: npm install
buildCommand
Build command, such as npm run build
, can be omitted if not required.
More Plugins
Please visit the CloudBase Framework Plugin List to use other plugins in combination
Documentation Resources
- CloudBase official website: https://tcb.cloud.tencent.com/
- CloudBase Static Website Setup Guide: https://docs.cloudbase.net/hosting/
- CloudBase Console: https://console.cloud.tencent.com/tcb