This commit is contained in:
Wes Bos 2023-02-21 16:29:26 -05:00
parent 72c7df8a66
commit acfef2b3f7
2 changed files with 3 additions and 5 deletions

View file

@ -6,6 +6,7 @@
[dev] [dev]
command = "remix watch" command = "remix watch"
port = 3000 port = 3000
autoLaunch = false
[[redirects]] [[redirects]]
from = "/*" from = "/*"

View file

@ -16,8 +16,6 @@ export default async function handleRequest(
responseHeaders: Headers, responseHeaders: Headers,
remixContext: EntryContext remixContext: EntryContext
) { ) {
console.log('😆');
console.log(request.url);
// // check if we have a cached response in memory // // check if we have a cached response in memory
// const cachedResponse = cache.get(request.url); // const cachedResponse = cache.get(request.url);
// if (cachedResponse) { // if (cachedResponse) {
@ -48,9 +46,8 @@ export default async function handleRequest(
} }
} }
); );
console.log(body);
// body // body.pip
// .on('data', (data) => { // .on('data', (data) => {
// console.log('data', data); // console.log('data', data);
// chunks.push(data); // chunks.push(data);
@ -62,7 +59,7 @@ export default async function handleRequest(
const headers = new Headers(responseHeaders); const headers = new Headers(responseHeaders);
headers.set("Content-Type", "text/html"); headers.set("Content-Type", "text/html");
new Response(body, { return new Response(body, {
headers, headers,
status: didError ? 500 : responseStatusCode, status: didError ? 500 : responseStatusCode,
}) })