Skip to content
This repository has been archived by the owner on May 13, 2024. It is now read-only.

Post excerpt is ignored #82

Closed
2 of 3 tasks
drbobsports opened this issue May 8, 2020 · 1 comment · Fixed by #83
Closed
2 of 3 tasks

Post excerpt is ignored #82

drbobsports opened this issue May 8, 2020 · 1 comment · Fixed by #83

Comments

@drbobsports
Copy link

drbobsports commented May 8, 2020

  • I confirm that this is an issue rather than a question.

Bug report

On index page only post summary is displayed. Even if post has excerpt part divided with

<!-- more -->

. It is ignored. I've struggled a lot of understanding why, until looked at the source code.

Steps to reproduce

  • I prepared a reproduction repo, here is the reproduction repo:

  • This issue doesn't need a reproduction repro, here is the steps to reproduce

Create post with "" tag separating excerpt and post content.

What is expected?

Display full excerpt.

What is actually happening?

See post summary is just 500 of first characters and not the full excerpt.

Other relevant information

I fixed this in child template BaseListLayout.vue with code:

        <p class="ui-post-summary" v-if="page.excerpt"  v-html="page.excerpt"></p>
        <p class="ui-post-summary" v-else>
          {{ page.frontmatter.summary || page.summary }}
        </p>
  • npx vuepress info:
    Environment Info:

    System:
    OS: Linux 5.3 Ubuntu 18.04.4 LTS (Bionic Beaver)
    CPU: (2) x64 Intel(R) Xeon(R) Platinum 8175M CPU @ 2.50GHz
    Binaries:
    Node: 8.10.0 - /usr/bin/node
    Yarn: Not Found
    npm: 3.5.2 - /usr/bin/npm
    Browsers:
    Chrome: Not Found
    Firefox: Not Found
    npmPackages:
    @vuepress/core: 1.4.1
    @vuepress/theme-default: 1.4.1
    vuepress: ^1.4.0 => 1.4.1
    npmGlobalPackages:
    vuepress: Not Found

@billyyyyy3320
Copy link
Member

I thought current approach (Defining summary in frontmatter) is enough, so Content Excerpt isn't supported in this theme.

It's more like a feature request than a bug report. Thanks for raising this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants