Open abhigyantrips opened 1 week ago
It looks like that something is broken in the cache directory. Can you try to remove the .content-collections
directory and try again?
that works! looks like after i added the transform method (with compileMarkdown
from @content-collections/markdown
), the cache directory wasn't regenerated.
is there an option to regenerate .content-collections
on every dev run?
is there an option to regenerate .content-collections on every dev run?
That should not be necessary. Content Collections adds a hash of the configuration's content to each cache key. As a result, if the configuration changes, the cache keys no longer match.
It looks like in your case, the .content-collections/cache/mapping.json
file was not fully written, leading to a parsing error. I can make the process more robust by starting without the cache if it cannot be read.
heya, i'm trying to use
content-collections
to load some metadata for my site. but every time i runnpm run dev
, i get the following error as output.here's my
next.config.mjs
here's my
content-collections.ts
, as per documentationand here are my dependencies:
from what i understand
Unexpected end of JSON input
errors are usually related to having blank values somewhere, but I'm pretty sure I've included all values. this is what my "memes" folder looks like:and this is the content in each of them: