I'm trying to implement Sitecore Forms
with the NextJS
app using this official document https://doc.sitecore.com/xp/en/developers/hd/211/sitecore-headless-development/implement-a-sitecore-form-in-a-jss-next-js-app.html
Since I'm using next js I'm passing sitecoreApiHost={''}
as mentioned in the document.
I have also followed this document to create Sitecore Form, created rendering, and added the same on the sample page; https://doc.sitecore.com/xp/en/developers/hd/211/sitecore-headless-development/walkthrough--using-a-sitecore-form-in-jss-applications.html
To simplify I have just added a redirect to the page as an action on Submit button with a couple of input boxes.
When the new rendering is added to the page for forms and after publishing I'm getting the following error;
'Unexpected token '<', "<!DOCTYPE "... is not valid JSON'
Appreciate any help on this topic, thank you.
Console
what are the other errors logged?