Warning in Next.js serverActions mod
Versions
-
@prismicio/next: 1.3.5 -
next: 13.5.3 - node: 18.18.0
Reproduction
I just want to use the PrismicNextLink component as it is in the example. But it throws an error when I set the following in the next.config.js:
experimental: {
serverActions: true,
},
<PrismicNextLink field={item.menu_item_link} >
{item.menu_item}
</PrismicNextLink>
I would need the new serverActions mode.
Additional Details
Warning: An empty string ("") was passed to the href attribute. To fix this, either do not render the element at all or pass null to href instead of an empty string. at a at LinkComponent (webpack-internal:///(ssr)/./node_modules/next/dist/client/link.js:105:19) at PrismicNextLink2 (webpack-internal:///(ssr)/./node_modules/@prismicio/next/dist/PrismicNextLink.js:18:99)
Steps to reproduce
You need to set the serverActions parameter in the next.config.js.
What is expected?
What is actually happening?
This issue has been labeled as a bug since it was created using the 🚨 Bug Report Template.
Hi there, thank you so much for the report!
Following our Maintenance Process, we will review your bug report and get back to you next Wednesday. To ensure a smooth review of your issue and avoid unnecessary delays, please make sure your issue includes the following:
- Information about your environment and packages you use (Node.js version, package names and their versions, etc.)
Feel free to attach a copy of your
package.jsonfile. - Any troubleshooting steps you already went through
- A minimal reproduction of the issue, and/or instructions on how to reproduce it
If you have identified the cause of the bug described in your report and know how to fix it, you're more than welcome to open a pull request address it. Check out our quick start guide for a simple contribution process.
If you think your issue is a question (not a bug) and would like quicker support, please close this issue and forward it to an appropriate section on our community forum: https://community.prismic.io
- The Prismic Open-Source Team