Security News
pnpm 10.0.0 Blocks Lifecycle Scripts by Default
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
Pagefind is a fully static search library that aims to perform well on large sites, while using as little of your users’ bandwidth as possible, and without hosting any infrastructure.
The full documentation on using Pagefind can be found at https://pagefind.app/.
This packages houses a wrapper for running the precompiled Pagefind binary, and also serves as a NodeJS indexing library that can be integrated into existing tools.
This is the recommended way of running Pagefind on a static site.
npx pagefind --site "public"
For more details on using the Pagefind binary, see Installing and running Pagefind, and the rest of the Pagefind documentation.
This package also provides an interface to the Pagefind binary directly as a package you can import.
import * as pagefind from "pagefind";
// Create a Pagefind search index to work with
const { index } = await pagefind.createIndex();
// Index all HTML files in a directory
await index.addDirectory({
path: "public"
});
// Add extra content
await index.addCustomRecord({
url: "/resume.pdf",
content: "Aenean lacinia bibendum nulla sed consectetur",
language: "en",
});
// Get the index files in-memory
const { files } = await index.getFiles();
// Or, write the index to disk
await index.writeFiles({
outputPath: "public/pagefind"
});
For more details on using Pagefind as a library, see Indexing content using the NodeJS API.
v1.3.0 (December 18, 2024)
--quiet
and --silent
flags when running the Pagefind CLI, which reduce the logging output to only warnings or only errors respectively.data-pagefind-ui-meta
attribute to the metadata tags on search results in the Default UI, allowing them to be targeted with CSS.
Date: April 19, 2024
will now have data-pagefind-ui-meta="date"
.data-pagefind-meta="phrase:this < that
would index the literal <
rather than a <
character.data-pagefind-meta
to capture the content of an element.Cannon
in CloudCannon
may have ranked the word incorrectly.FAQs
Implement search on any static website.
The npm package pagefind receives a total of 60,936 weekly downloads. As such, pagefind popularity was classified as popular.
We found that pagefind demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
Product
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.
Research
Security News
Socket researchers have discovered multiple malicious npm packages targeting Solana private keys, abusing Gmail to exfiltrate the data and drain Solana wallets.