Twikoo
一个简洁、安全、免费的静态网站评论系统,基于 腾讯云开发。
使用
npm i -D twikoo请配置 provider: "Twikoo",并将你的服务端地址传入 envId 选项:
import { commentPlugin } from '@vuepress/plugin-comment'
export default {
plugins: [
commentPlugin({
provider: 'Twikoo',
envId: 'https://twikoo.example.com',
}),
],
}部署后端
请先按照 官方文档 部署好后端。
提示
插件会自动设置 lang(为 zh-CN 或 en)、path(页面的评论标识符)和 el。
选项
envId必填
stringVercel 地址或腾讯云环境 ID。
参考:部署后端。
region
string默认值
'ap-shanghai'腾讯云区域。
客户端配置
你可以使用 defineTwikooConfig 函数来配置 Twikoo:
import { defineTwikooConfig } from '@vuepress/plugin-comment/client'
import { defineClientConfig } from 'vuepress/client'
defineTwikooConfig({
// Twikoo 选项
})