From 500e672ba234389234a17b50e70f75be087ddcce Mon Sep 17 00:00:00 2001 From: "@beer" <47961062+iiio2@users.noreply.github.com> Date: Fri, 29 Nov 2024 16:48:25 +0600 Subject: [PATCH] chore(examples): fix typos (#893) --- examples/body.ts | 4 ++-- examples/errors.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/body.ts b/examples/body.ts index 15a92a6c..bb9fd49a 100644 --- a/examples/body.ts +++ b/examples/body.ts @@ -3,10 +3,10 @@ import { createApp, createRouter, readJSONBody } from "h3"; export const app = createApp(); const router = createRouter() - .get("/", () => "use POST method to try!") + .get("/", () => "use GET method to try!") .post("/", async (event) => { const body = await readJSONBody(event); - // Use can also use `readFormDataBody` to get a FormData object, `readMultiPartFormData` to get an array of MultiPartData or `readRawBody` to get a Buffer. + // You can also use `readFormDataBody` to get a FormData object, `readMultiPartFormData` to get an array of MultiPartData or `readRawBody` to get a Buffer. return { body, }; diff --git a/examples/errors.ts b/examples/errors.ts index 1e932112..3f86303a 100644 --- a/examples/errors.ts +++ b/examples/errors.ts @@ -4,7 +4,7 @@ export const app = createApp({ debug: true }); const router = createRouter() .get("/", () => { - // Always "throw" errors to propgate them to the error handler + // Always "throw" errors to propagate them to the error handler throw createError({ statusMessage: "Simple error!", statusCode: 301 }); }) .get("/complexe-error", () => {