funkydan2 / hugo-kiera

Kiera - A Hugo Theme for writing
https://hugo-kiera.netlify.app
MIT License
71 stars 53 forks source link

Enabling Utterances comments #36

Closed tarquin-the-brave closed 4 years ago

tarquin-the-brave commented 4 years ago

Hi,

I'm having a little trouble enabling commenting with utterances.

I've followed the utterances docs and installed the utterance app on github, enabling it for my blog repo. Although I couldn't find the "Blog Post ↔️ Issue Mapping" config anywhere on Github.

I've copied the two fields from the example config in the Keira theme into my hugo config:

[params]                                                                                                                                              
    utterancesRepo = "https://github.com/tarquin-the-brave/blog"                                                                                      
    utterancesIssueTerm = "pathname" 

I didn't know what to put for utteranceIssueTerm so I just left as it is.

I've rebuilt with hugo and committed and pushed the changes under the docs/ directory. And commenting hasn't appeared on any blog posts.

Is there something I'm missing? What am I supposed to set utterancesIssueTerm to?

Thanks!

funkydan2 commented 4 years ago

Try setting utterancesRepo = "tarquin-the-brave/blog".

Sorry the example config was wrong...I don't use commenting on my site, so I'd never tested it.

I've currently got a fix in the commenting branch - could you check that?

tarquin-the-brave commented 4 years ago

Thanks, that's done it! I've tested using the commenting branch of the theme, and the comments appear. And the example for utternancesRepo in that branch looks good :+1:

I tried removing utterancesIssueTerm, but then the commenting stopped working, so I've put it back to:

utterancesIssueTerm = "pathname"

Any idea what that field is supposed to be for?

funkydan2 commented 4 years ago

Thanks - I'll merge that branch soon.

The utterancesIssueTerm is a setting where you can have different ways the issues on GitHub are named. Have a look at https://utteranc.es...in the Blog Post<->Issue Mapping section - there are 6 different ways you can do this...and the way it works in this theme is you have to have one set.