hexojs / hexo

A fast, simple & powerful blog framework, powered by Node.js.
https://hexo.io
MIT License
39.35k stars 4.84k forks source link

I have a question that permalink seems to have a bug #4659

Closed liuyib closed 3 years ago

liuyib commented 3 years ago

Check List

Please check followings before submitting a new issue.

Question

If / is missing at the end of permalink, the webpage will be downloaded and saved automatically when the article link is accessed.

Environment & Settings

Hexo@5.4.0, (I have no test other version of Hexo) Chrome@latest, FireFox@latest, (I have no test other browser)

Node.js & npm version

$ node -v
v12.18.4

$ npm -v
6.14.6

Your site _config.yml (Optional)

permalink: :year/:month/:day/:title

Your theme _config.yml (Optional)

Hexo and Plugin version(npm ls --depth 0)

Your package.json package.json

Others

Steps to reproduce, after setting permalink, remove the / at the end, for example (permalink: :category/:title), and then visit any article url (you may need to refresh the browser manually), you will find that the browser will Save web pages automatically

For more info, see:

I know this seems to be a usage problem, but I want to ask whether hexo can be compatible with this problem. After all, the lack of a semicolon at the end will cause the whole question to be too strict. For novices, it is impossible to troubleshoot the problem.

Finally, if it really can’t be solved at the code level, I hope it should be written in the documentation: 'when setting permalink, the ending / sign must exist'

baoang commented 3 years ago

I am using the very old ver, v3.x, and permalink works ok, no need to put a slash at the end of permalink. It looks this is a new function of higher ver.

github-actions[bot] commented 3 years ago

This issue has been automatically marked as stale because lack of recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

uiolee commented 12 months ago

fixed by hexojs/site#1734