Complete the code to throw a 404 response using Remix's Response class.
throw new Response('Not Found', { status: [1] });
The HTTP status code 404 means 'Not Found'. Using it in the Response constructor tells Remix to send a 404 error.
Complete the code to throw a 403 Forbidden error with a custom message.
throw new Response([1], { status: 403 });
The message 'Access Denied' fits a 403 Forbidden error, indicating the user cannot access the resource.
Fix the error in throwing a 500 Internal Server Error response.
throw new Response('Server Error', { status: [1] });
The status code 500 means 'Internal Server Error', which is correct for server errors.
Fill both blanks to throw a 401 Unauthorized error with a message.
throw new Response([1], { status: [2] });
The message 'Unauthorized Access' fits a 401 error, and the status code 401 means 'Unauthorized'.
Fill all three blanks to throw a 302 Redirect response with a Location header.
throw new Response(null, { status: [1], headers: { [2]: [3] } });A 302 status code means temporary redirect. The Location header tells the browser where to go, here to /login.
