feat: replace ohmyfetch with ofetch

This commit is contained in:
wobsoriano
2022-12-20 20:13:48 -08:00
parent 8168a46985
commit 7995e892db
7 changed files with 12 additions and 12 deletions

View File

@@ -29,7 +29,6 @@ export const router = trpc.router<Context>()
.mutation('addTodo', {
input: TodoShape,
async resolve(req) {
console.log(req.input)
return await $fetch<Todo>(`${baseURL}/todos`, {
method: 'POST',
body: req.input,
@@ -43,7 +42,7 @@ export async function createContext(event: H3Event) {
// This is just an example of something you'd might want to do in your ctx fn
// const x = useCookies(event)
console.log(event.req.headers)
console.log(event.node.req.headers)
return {