linux怎么查看本机内存大小
303
2022-09-02
为 Hexo 博客添加 valine 评论系统
注册 LeanCloud
由于 valine 评论系统是放在 LeanCloud 上的,因此需要先打开 网址注册一个 LeanCloud 账号。
注册完成后创建一个应用,比如名字为 blog,然后进入应用,在 设置 -> 应用 Keys 中找到 APP ID 和 APP Key。
Hexo 配置
在 hexo 工程下执行如下命令安装插件
npm install
在 _config.yml 文件末尾插入如下内容(可以是 hexo 或 theme 的 _config.yml)
# Valine# For more information: enable: false appId: # your leancloud application appid appKey: # your leancloud application appkey serverURLs: # When the custom domain name is enabled, fill it in here placeholder: Just go go # comment box placeholder avatar: mm # gravatar style meta: [nick, mail, link] # Custom comment header pageSize: 10 # pagination size visitor: false # leancloud-counter-security is not supported for now. When visitor is set to be true, appid and appkey are recommended to be the same as leancloud_visitors' for counter compatibility. Article reading statistic comment_count: true # If false, comment count will only be displayed in post page, not in home page recordIP: false # Whether to record the commenter IP
将 enable 项改为 true,复制前面生成的 appId 和 appKey。
配置域名
记得在 Leancloud -> 设置 -> 安全中心 -> Web 安全域名 把你的域名加进去。
否则网页会出现 “valine 未经授权的操作,请检查你的AppId和AppKey.” 提示。
版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。
发表评论
暂时没有评论,来抢沙发吧~