Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

staticman_v3 comments form not showing up #2031

Closed
sseneca opened this issue Jan 17, 2019 · 7 comments
Closed

staticman_v3 comments form not showing up #2031

sseneca opened this issue Jan 17, 2019 · 7 comments

Comments

@sseneca
Copy link

sseneca commented Jan 17, 2019

I'm having issues with getting staticman comments to work. staticman v2 has the api limit it's been having but so I've instead been trying to get staticman v3 to work. I've installed the app to the repo, and I've added a staticman.yml. The comments provider is set to staticman_v3, and I copy+pasted the staticman_v2.html file into /_includes/comments-providers/ only renaming it. I've also changed the endpoint to what is the v3 url (according to eduardoboucas/staticman#243 (comment)).

afaik, I've done all I need to but the comment section won't show up. Is there something I'm missing? I'm pretty sure I've filled out all the required settings as well, which was an issue I saw other people were having.

It might be an issue with staticman considering staticman_v3 isn't really finished yet, but I saw other people getting it working and I was wondering if mine wasn't because of something I was doing incorrectly.

Thanks!

@mmistakes
Copy link
Owner

The comment section not showing is one of two things.

  1. You are missing a required variable that will trigger it to show. This is easy to find by looking at the conditionals around the form.
  2. More likely you didn't build your site with JEKYLL_ENV=production. Jekyll builds in development by default. I have no clue what you're deployment process is, but if you're hosting anywhere except GitHub Pages (where they automatically enabled production environment variable, you need set it yourself.

@mmistakes
Copy link
Owner

Also, the theme doesn't have support for staticman_v3. So setting it as a comment provider isn't going to do anything. There is no {% when "staticman_v3" %} logic in the theme.

@mmistakes
Copy link
Owner

I don't use v3 and I didn't directly add the support for using a different endpoint. Which is why the documentation is a bit off.

I believe what you want to do is use staticman_v2 provider, but add your endpoint under the staticman key. Everything else is setup as you would if you were using v2.

@sseneca
Copy link
Author

sseneca commented Jan 17, 2019

Yeah like you said using staticman_v2 and changing the endpoint now makes the comments form appear, thanks. Now I have to figure out why comments can't actually be submitted...

@VincentTam
Copy link
Contributor

I've updated the documentation in #2043 to reflect this. Please review.

@NicolayP
Copy link

Hi, I had the same issue and I found out that comments.html has an if statement with site.comments.staticman.branch. I expect this to be set up in staticman.yml but apparently it uses only the fields set up in _config.yml. Solved the issue by indenting all the fields related to staticman in the comments section of the config. Don't know if that the correct way to do it but it solved the issue for me.

@mmistakes
Copy link
Owner

@NicolayP you might be looking at older version/fork. This was cleaned up in the docs in #2043.

https://mmistakes.github.io/minimal-mistakes/docs/configuration/#staticman-v3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants