Skip to content

Instantly share code, notes, and snippets.

@ManUtopiK
Created July 23, 2023 17:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ManUtopiK/409fb7a0b4114e9f22b9701e2097c693 to your computer and use it in GitHub Desktop.
Save ManUtopiK/409fb7a0b4114e9f22b9701e2097c693 to your computer and use it in GitHub Desktop.
Netlify edge function's geo prop
export default async (request, context) => {
return new Response(
JSON.stringify({
...context.geo,
ip: context.ip,
}),
{ headers: { 'content-type': 'application/json' } }
);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment