Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "read more" link to excerpts #56

Closed
jomei opened this issue May 26, 2020 · 2 comments
Closed

Add "read more" link to excerpts #56

jomei opened this issue May 26, 2020 · 2 comments

Comments

@jomei
Copy link
Contributor

jomei commented May 26, 2020

Hi!
Currently on the posts page it's not obvious that an excerpt is not a full post. I think it would be nice to have some way to add some kind of "read more" link with custom text.

@DotIN13
Copy link
Contributor

DotIN13 commented May 27, 2020

You could fork the repo and add your own Read More button.

You need to modify _layout/home.html: 53, for example as follows:

<div class="post">
{%- if site.show_excerpts -%}
{{ post.excerpt }}
{%- endif -%}
<a class="read-more-link" href="{{ post.url | relative_url }}">Read More</a>
</div>

and _sass/plain.scss as follows

.post {

  .read-more-link {
    font-family: Raleway, sans-serif;
    margin-bottom: 1em;
  }

  p {
    margin-bottom: 0.25rem;
  }
}

tEWQB9.png

@jomei
Copy link
Contributor Author

jomei commented May 28, 2020

Thank you, @DotIN13 It's a good solution =)

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

No branches or pull requests

2 participants