You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The vitepress site I'm building has several different areas like projects, posts, tweets, videos, etc. I currently have createContentLoader for each area like such
However wondering if it's possible to have a generic loader that accepts as path as argument so it can be reused in other areas. Also areas will be lots of markdowns, so would like pagination, something like this:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
The vitepress site I'm building has several different areas like
projects
,posts
,tweets
,videos
, etc. I currently havecreateContentLoader
for each area like suchHowever wondering if it's possible to have a generic loader that accepts as path as argument so it can be reused in other areas. Also areas will be lots of markdowns, so would like pagination, something like this:
However when I try to use
createContentLoader
when it's not in a file likeposts.data.js
I get this error.Has anyone else ran into this same problem? Any ideas how to make
createContentLoader
more reusable?Beta Was this translation helpful? Give feedback.
All reactions