Node version(node -v): 7.8.9
Your site _config.yml (Optional):
root: /blog/
url: http://127.0.0.1:4000/ # Note: don't forget to modify the CNAME file to your url
permalink: :title-:abbrlink/
permalink_defaults:
Your theme _config.yml (Optional):
Nothing relevant
Hexo and Plugin version(npm ls --depth 0):
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
I've placed <%= page.permalink %> in post.ejs and the result is http://127.0.0.1:4000/El-meu-primer-post-ada5698b/
This link is not working as root is /blog/. Also <%= config.url + config.root + (page.path||'').replace('index.html', '') %> produces http://127.0.0.1:4000/blog/El-meu-primer-post-ada5698b/ which is ok.
I've tried to change permalink directive in _config.yml to include :root with no success. Also this change breaks the links in home page. index.ejs:
<% page.posts.each(function(post){ %>
<div class="post-preview">
<a href="<%- config.root %><%- post.path %>">
Am I missing something?
The url should include the root path: http://127.0.0.1:4000/blog
The new config file has mentioned this in comment:

@NoahDragon thanks
The url should include the root path:
http://127.0.0.1:4000/blog
So what I guess is that _config.yml should be:
url: http://127.0.0.1:4000/blog
root: /
In this case, why is root parameter for? Just for curiosity...
@miqmago Good question. I'm not sure, and will have a look.
Maybe, it will be used to deploy.
I think that this is important BUG.
Most helpful comment
@NoahDragon thanks
So what I guess is that
_config.ymlshould be:In this case, why is
rootparameter for? Just for curiosity...