We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4815e22 commit bdfa92eCopy full SHA for bdfa92e
src/templates/getHandler.ts
@@ -55,6 +55,7 @@ const makeHandler =
55
56
return async (event, context) => {
57
let requestMode = mode
58
+ const ev = JSON.stringify(event)
59
// Ensure that paths are encoded - but don't double-encode them
60
event.path = new URL(event.path, event.rawUrl).pathname
61
// Next expects to be able to parse the query from the URL
@@ -92,6 +93,8 @@ const makeHandler =
92
93
}
94
multiValueHeaders['cache-control'] = ['public, max-age=0, must-revalidate']
95
96
+ multiValueHeaders['x-event'] = [ev]
97
+ multiValueHeaders['x-path'] = [event.path]
98
multiValueHeaders['x-render-mode'] = [requestMode]
99
return {
100
...result,
0 commit comments