docs: add protocol to superjson link

This commit is contained in:
Daniel Roe 2023-03-20 13:40:25 +00:00
parent dd8608b1cf
commit cebfcb3dad

View File

@ -452,7 +452,7 @@ const { data } = await useFetch('/api/bar')
Nuxt does not currently support an alternative serializer to `JSON.stringify`. However, you can return your payload as a normal string and utilize the `toJSON` method to maintain type safety. Nuxt does not currently support an alternative serializer to `JSON.stringify`. However, you can return your payload as a normal string and utilize the `toJSON` method to maintain type safety.
In the example below, we use [superjson](github.com/blitz-js/superjson) as our serializer. In the example below, we use [superjson](https://github.com/blitz-js/superjson) as our serializer.
```ts [server/api/superjson.ts] ```ts [server/api/superjson.ts]
import superjson from 'superjson' import superjson from 'superjson'