컨텐츠로 건너뛰기

The middleware returned something that is not a Response object.

MiddlewareNotAResponse: Any data returned from middleware must be a valid Response object.

미들웨어가 Response 객체가 아닌 것을 반환할 때 개발 모드에서 발생합니다.

예시:

import {defineMiddleware} from "astro:middleware";
export const onRequest = defineMiddleware(() => {
return "string"
});