Skip to content
Permalink
Browse files

feat($core): enable .html suffix by default

This change respects Yuque's convention
  • Loading branch information...
ulivz committed Feb 8, 2019
1 parent 4a22650 commit 9a5167f748e1f9ea5b3a671bc97e274f67c7b632
Showing with 4 additions and 4 deletions.
  1. +1 −1 docs/.vuepress/config.js
  2. +1 −1 lib/index.js
  3. +2 −2 lib/toc.js
@@ -8,7 +8,7 @@ module.exports = {
// repoUrl: 'https://www.yuque.com/ant-design/course',
home: {
actionText: 'Getting Started →',
actionLink: '/intro/',
actionLink: '/intro.html',
heroImage: 'https://cdn.nlark.com/yuque/0/2019/png/242808/1549571925285-2372b0a0-0234-421c-a139-00ea16f1a106.png',
footer: `Copyright © ULIVZ`,
features: [
@@ -140,7 +140,7 @@ module.exports = (opts, ctx) => {
? postContent
: `# ${title} \n\n ${postContent}`

const permalink = `/${slug}/`
const permalink = `/${slug}.html`
await ctx.addPage({
content,
frontmatter,
@@ -120,7 +120,7 @@ function getLeaf({
title,
slug
}) {
return [`/${slug}/`, title]
return [`/${slug}.html`, title]
}

/**
@@ -141,7 +141,7 @@ function getBranch({
children: []
}
if (slug && slug !== '#') {
group.path = `/${slug}/`
group.path = `/${slug}.html`
}
return group
}

0 comments on commit 9a5167f

Please sign in to comment.
You can’t perform that action at this time.