Security News
ESLint is Now Language-Agnostic: Linting JSON, Markdown, and Beyond
ESLint has added JSON and Markdown linting support with new officially-supported plugins, expanding its versatility beyond JavaScript.
github-pages-tags
Advanced tools
You are display tags list on each post in your github pages website and this is good.
But, usually, you want that those tags will be links to a tag page which will display all the posts
which contains the tag, right?
The problem is that jekyll
is a static "language" so you have to generate each page as static file.
Will you do this manually? I don't think so.
After the package have been installed, this package modify the package.json
and add to it a postcommit script.
This script is reading all the tags in the site and generate a .md
file for each of them under /tags
folder.
npm install github-pages-tags --save
create a tag.html in layout folder which will be the tag template. This file should looks like:
---
layout: default
---
<h1>`{{ page.title }}` posts</h1>
<div class="view">
{% for post in site.posts %}
{% if post.tags contains page.title %}
{% include post-item.html post=post last=forloop.last %}
{% endif %}
{% endfor %}
</div>
You can custom the plugin behavior by creating github-pages-tags.config.js
github-pages-tags.config.json
.
Here is the options:
{
// tag page title
"title": "{{tag}}}",
// tag page meta description
"description": "Here are all the posts that related to {{tag}}",
// generate only tag who have more than `minPostCount` posts. See link below:
"minPostCount": 0
}
{{tag}}
will be replaced by the actuall tag name.minPostCount
- (Why is good?)FAQs
A package to generate tags pages to github pages website
The npm package github-pages-tags receives a total of 4 weekly downloads. As such, github-pages-tags popularity was classified as not popular.
We found that github-pages-tags demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
ESLint has added JSON and Markdown linting support with new officially-supported plugins, expanding its versatility beyond JavaScript.
Security News
Members Hub is conducting large-scale campaigns to artificially boost Discord server metrics, undermining community trust and platform integrity.
Security News
NIST has failed to meet its self-imposed deadline of clearing the NVD's backlog by the end of the fiscal year. Meanwhile, CVE's awaiting analysis have increased by 33% since June.