diff --git a/_config.yml b/_config.yml index 96d84bf..416109c 100644 --- a/_config.yml +++ b/_config.yml @@ -234,6 +234,7 @@ comment: repository: # Repository name to store issues client_id: # GitHub Application Client ID client_secret: # GitHub Application Client Secret + proxy: # GitHub oauth request reverse proxy for CORS # Twikoo # See: https://github.com/imaegoo/twikoo diff --git a/layout/_partial/comment/gitalk.ejs b/layout/_partial/comment/gitalk.ejs index 746a42b..a26c746 100644 --- a/layout/_partial/comment/gitalk.ejs +++ b/layout/_partial/comment/gitalk.ejs @@ -5,7 +5,8 @@ const { client_secret, repository, github_id, - github_admins + github_admins, + proxy } = theme.comment?.gitalk let cdn_css = '//cdn.jsdelivr.net/npm/gitalk/dist/gitalk.css' let cdn_js = '//cdn.jsdelivr.net/npm/gitalk/dist/gitalk.min.js' @@ -46,6 +47,7 @@ if (t_cdn_enable === true) { owner: '<%= github_id %>', admin: '<%= github_admins || [github_id] %>', id: __gitalk__pathname, + proxy: '<%= proxy %>', language: '<%= config.language %>' }).render('gitalk-container'); } catch (e) {