Comments (6)
Hello! 👋
Hmm yes I see. It is intentional that data-pagefind-ignore
only affects the indexing — for example the <head>
is an implicit data-pagefind-ignore
, but we still want to pluck filters and metadata out of it. In another case, I have sites where I wrap a sidebar navigation in data-pagefind-ignore
, but some data inside that sidebar is useful for setting up a filter group.
I might look at expanding that attribute to take an argument. Then the current argumentless version would imply data-pagefind-ignore="index"
, and we could add a data-pagefind-ignore="all"
which also omits filters and metadata.
How does that sound to you?
from pagefind.
That would work, thanks.
from pagefind.
Another thought here is that you can fall back to the open graph image when the content search has not provided any results, I don't think that this is something that can currently be configured.
from pagefind.
Yes good call. If you're defining your own data-pagefind-meta
then subsequent definitions will overwrite the earlier ones, but there isn't a configuration to have the auto-detected image take precedence.
One way to allow this would be adding some configuration to the Pagefind UI along the lines of
{
image: ["image", "og-image"]
}
Where the UI tries to use those keys in order for the image. Which would let the default image stay as meta.image
, and you could separately tag your open graph image as og-image
. Then at the UI end it can fall back to the og-image
if no auto image was found.
from pagefind.
That could be a good approach, this meta data would also need to be ignored in the skipMeta
in that case.
from pagefind.
Hi @vanbroup 👋
Some fixes have landed in Pagefind v0.5.0 🎉
data-pagefind-ignore="all"
has been implemented as described above- An alternate solution for fallback content was implemented, allowing you to tag your og image as
data-pagefind-default-meta
from pagefind.
Related Issues (20)
- Making result (pagefind-ui__result) clickable instead of title HOT 5
- Broken image sources in Hugo with base64 encoded images HOT 2
- Pagefind wasn't able to build an index HOT 1
- How do I get pagefind to work with the nextjs app router? HOT 1
- Dark mode in default pagefind-modular-ui.css HOT 6
- H1 elements not being indexed HOT 2
- [Feature request] Score exact name of page highly HOT 1
- The path to the image is not found
- Special characters (p.e. Umlauts) in page's file names are not escaped, causing not working links HOT 2
- CSS Validation Parse Error: .pagefind-ui__button.svelte-193m69l | Value Error : color ----pagefind-ui-primary HOT 1
- Runtime error "unreachable executed" when search term contains emoticon HOT 1
- Support of specific "target" for <a> links by default UI to open result documents in different frame HOT 2
- ModularUI results do not update on scroll HOT 4
- Sort ModularUI FilterPills HOT 2
- Difference in the results by including `a` in the middle. HOT 4
- Problem with domains and subdomains HOT 4
- Error in documentation for the bundle path option
- Consider exposing the types on the Pagefind client
- feature request: Python wrapper package, Python API HOT 2
- Allow to specify the path of the config file
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pagefind.