Share: A new comment system ---- Waline access mkdocs #4166
bigbigDreamer
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Now, we can use a new comment system ---- waline in
Mkdocs.Some basic configurations can be found in the original documentation, I'll just list here how to access.
mkdocs.yml. 📦docs-project ┣ 📂docs ┣ 📂overrides ┃ ┗ 📜main.html ┣ 📜.gitignore ┣ 📜mkdocs.yml ┗ 📜package.jsoncore codeinmain.html{% extends "base.html" %} {% block content %} {{ super() }} {% if page and page.meta and page.meta.template %} <div id="waline-container" style="margin-top: 80px;padding-top: 12px;"></div> {% endif %} {% endblock %} {% block styles %} {{ super() }} <link rel="stylesheet" href="https://unpkg.com/@waline/client@v2/dist/waline.css" /> <style> .md-grid { max-width: 1200px; } </style> {% endblock %} {% block scripts %} {{ super() }} {% if page and page.meta and page.meta.template %} <script src="https://unpkg.com/@waline/client@v2/dist/waline.js"></script> <script> Waline.init( { el: '#waline-container', serverURL: "http://xxxxxx", } ) </script> {% endif %} {% endblock %}meta configfor yourevery .md fileNow! we can use~~~
Beta Was this translation helpful? Give feedback.
All reactions