https://github.com/pimlie/nuxt-issues
clone repro & run yarn dev & browse to http://localhost:3000
A page that says hello is displayed
An error 'NuxtServerError: Cannot stringify a function' occures
This is due to #3913, serialize could serialize functions but devalue cant. Although I can fix my project to not return a method, this is actually a breaking change.
Where now used devalue, there was serialize with isJson which wasnt serializing functions, it was skipping them. And in store there should be only serializable data.
This is not store, but asyncData. Anyway, will regard as a feature then ;)
@pimlie So how did you fix this issue? I am facing the same one
In my case I returned a closure function in asyncData, the solution was to just move that closure definition to data instead. (it was actually some configuration of a graph which had no real use there to begin with).
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.