docs: update topic to avoid displaying issue#772
docs: update topic to avoid displaying issue#772juzhiyuan merged 1 commit intoapache:masterfrom yzeng25:1125_CVE_EN_duplication
Conversation
|
Good catch!! This may be a bug from Docusaurus? |
Well, not necessarily. It is most people's first instinct to look at file names when the above problem occurs. File name is used to generate urls, thus duplicated file names is prohibited from the very beginning, i.e. creating two files with the same file names in the same directory is not allowed. But if you take a step back and have a look: in what kind of scenario would a person create two or more articles with the same With this being said, each article has a unique title is a very common-sense thing. I would rather call this a human-like thinking logic than a bug. |
😄 |
Fixes: #771
Changes:
Currently, the website displays two identical articles on the first page of blog.
After some researching and testing, I find the cause of this problem. While it is completely fine to post multiple articles in the same date directory, the
titleof articles under the same directory must be identical and unique.In other words, when adding two or more articles in the same date directory, you need to make sure each article's
titlemust be different.This problem is caused by two articles with the same
title.After updating the title of an article, then
yarn startrun it locally, it works out fine.In addition, I also checked the files in
apisix-website/website/i18n/zh/docusaurus-plugin-content-blog/2021/11/23/directory and run it locally. It works fine, so there is no need to modify files in this directory.For future changes, if you are adding two or more articles in the same date directory, please make sure they have different
title. Useyarn startto run it locally before submission is also suggested.