
Research
/Security News
npm Author Qix Compromised via Phishing Email in Major Supply Chain Attack
npm author Qix’s account was compromised, with malicious versions of popular packages like chalk-template, color-convert, and strip-ansi published.
eleventy-plugin-related
Advanced tools
Filter and/or short code to rank text documents by similarity.
Install using NPM or similar.
npm i eleventy-plugin-related
eleventyConfig.addFilter(
"related",
require("eleventy-plugin-related").related({
serializer: (doc) => [doc.title, doc.link ?? "", doc.text ?? ""],
weights: [10, 1, 3],
})
);
Usage in a NunJucks template would look similar to the following.
<h3>Related</h3>
<ul>
{% for result in story | related(stories) %}
<li>{{ result.relative }} - {{ result.document.title }}</li>
{% endfor %}
</ul>
For more complex options, check out the package related-documents, on which this package is based.
FAQs
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.
Research
/Security News
npm author Qix’s account was compromised, with malicious versions of popular packages like chalk-template, color-convert, and strip-ansi published.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.