Cannot read properties of undefined (reading 'currentPage')
Disabling the blog through the config.yaml
apps:
blog:
isEnabled: false
postsPerPage: 6
causes a TypeError:
This error began for me once I updated to astro v5.0.5. I am unsure how to resolve it. Has anyone had the same issue?
Same error here. Log file says:
The collection "posts" does not exist or is empty. Ensure a collection directory with this name exists.
So it should be related to the loader not finding the content collection. In the patch which upgrades astrowind to 5, there is also a "git mv " of src/content -> src/data/.
Testing with the plain AstroWind repo, it does not seem like the blog collection are able to load properly. The blog list is empty and going to one of its posts returns 404.
Local icons changed, reloading
24:26:53 watching for file changes...
The collection "post" does not exist or is empty. Ensure a collection directory with this name exists.
24:27:00 [200] / 883ms
24:27:01 [200] /_image 701ms
24:27:06 [200] /blog 33ms
24:27:10 [WARN] [router] A `getStaticPaths()` route pattern was matched, but no matching static path was found for requested path `/get-started-website-with-astro-tailwind-css`.
Possible dynamic routes being matched: src/pages/[...blog]/[category]/[...page].astro, src/pages/[...blog]/[tag]/[...page].astro, src/pages/[...blog]/[...page].astro, src/pages/[...blog]/index.astro.
24:27:10 [404] /get-started-website-with-astro-tailwind-css 16ms
I opened a discussion around this last week
https://github.com/onwidget/astrowind/discussions/571
I removed pages/..blog/category to get things working
I have the same error when I try to upgrade from Astro version 4 to 5. Looking forward to possible solutions
I had the same error here after upgrading Astro to 5. I noticed it happens when running astro dev, but it won't happen after running astro build && astro preview.
I'll just stick with Astro 4 for a while 🤣
actually can I develop locally without crashing error when updating to latest astro version, ("astro": "^5.1.3") however still the issue is there:
[WARN] [router] A getStaticPaths() route pattern was matched, but no matching static path was found for requested path /123.
Possible dynamic routes being matched: src/pages/[...blog]/[category]/[...page].astro, src/pages/[...blog]/[tag]/[...page].astro, src/pages/[...blog]/[...page].astro, src/pages/[...blog]/index.astro.
[404] /123 7ms
I've solved it, updated and copied code again from source and noticed indeed the extra folder when upgrading to astro 5.
I was able to upgrade to Astro 5, and I also updated some dependencies and integrations except for React. I think this latest React update was causing the problems. In the future I will try to update the React integration to see if everything behaves well.