liang2kl / mkdocs-blogging-plugin

Add blogging feature to your MkDocs site.
https://liang2kl.github.io/mkdocs-blogging-plugin
MIT License
84 stars 17 forks source link

[BUG] Searching page with blog content #29

Closed LorhanSohaky closed 2 years ago

LorhanSohaky commented 2 years ago

Describe the bug A clear and concise description of what the bug is.

To Reproduce

  1. Creates index.md:
    
    ---
    title: Home
    hide:
    - navigation
    search:
    exclude: true
    ---

See my posts

{{ blog_content }}


2. Creates a blog post:
```md
---
title: How to do this
description: Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
# Additional metadata can be used in the template
author: Adm
tags:
  - test

---

# How to do this
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
  1. Edits mkdocs.yml:

    plugins:
    - awesome-pages
    - search:
      lang: pt
    
    - blogging:
      dirs:
        - blog
      locale: pt
      time_format: '%d/%m/%y'
      meta_time_format: '%Y-%m-%d %H:%M:%S'
      theme:
        name: button
        options:
          label: 'Read more'
      features:
        tags:
          index_page: tags.md
          insert: top

Expected behavior That the content of the page appears or that it is not listed

Screenshots image

Environment (please complete the following information):

liang2kl commented 2 years ago

Sorry for the late response.

It seems that the problem is with the search plugin instead of the bloggin plugin. As mentioned in Material for MkDocs's documentation, the exclusion feature is only available with their sponsor version.

LorhanSohaky commented 2 years ago

Hmmm okay, thanks!