Skip to content

Latest commit

 

History

History
29 lines (21 loc) · 923 Bytes

File metadata and controls

29 lines (21 loc) · 923 Bytes

博客小程序案例

预览 DEMO

下载或clone代码包

git clone https://github.com/TencentCloudBase/tcb-demo-blog.git

配置小程序 id

微信开发者工具,打开上一步下载下来的代码仓库,填入小程序的 appid(使用云开发能力必须填写 appid)。

安装云函数依赖

// 安装依赖
cd cloud/functions/addblog/
npm install --production

上传云函数

在IDE中,右键云函数对应的文件夹,点击“上传并部署”菜单

新建collection

在小程序开发IDE中的,[云开发控制台] -> [数据库] 中,添加集合 blog

体验

点击小程序开发IDE中的“预览”,用微信扫一扫即可体验