Artalk 选项

配置

详见 Artalk 配置open in new window

  • el pageTitle, pageKeysite 选项为插件的保留选项,将从 VuePress 配置中自动推断,不可设置。

  • imgUploaderavatarURLBuilder 这两个函数选项只能在客户端配置。

插件配置

你可以直接在插件选项中配置可序列化的选项:

import { defineUserConfig } from 'vuepress'
import { commentPlugin } from '@vuepress/plugin-comment'

export default defineUserConfig({
  plugins: [
    commentPlugin({
      provider: 'Artalk',
      // 其他选项
      // ...
    }),
  ],
})

客户端配置

你可以使用 defineArtalkConfig 函数来配置 Artalk。

import { defineClientConfig } from 'vuepress/client'
import { defineArtalkConfig } from '@vuepress/plugin-comment/client'

defineArtalkConfig({
  // Artalk 选项
})

export default defineClientConfig({
  // ...
})
Last Updated:
Contributors: jiaomy