AI OnAI Off
We managed to found it ourself.
We had defined our own extension method ToJson in one of our libaries and since Episerver does not define exactly what method it will use it selected ours and that one was not compatible with the Forms code.
Now I am waiting on Episerver to update that file so they define what extension method to use or fix so their objects can be serielized with DataContractJsonSerializer.
I have just installed Episerver Forms and when I try it out (without any customization) I get this error:
That (I think) make me ge another error in javascript:
And that is happening in this function
I am using:
<package id="EPiServer.Forms" version="4.25.1" targetFramework="net472" />
<package id="EPiServer.Forms.Core" version="4.25.1" targetFramework="net472" />
<package id="EPiServer.Forms.UI" version="4.25.1" targetFramework="net472" />