{"id":19178082,"url":"https://github.com/cmdruid/break-vercel","last_synced_at":"2026-06-23T07:31:45.626Z","repository":{"id":234179308,"uuid":"719275818","full_name":"cmdruid/break-vercel","owner":"cmdruid","description":"A simple web project to demonstrate some issues with vercel, CORS, and custom headers.","archived":false,"fork":false,"pushed_at":"2023-11-15T20:37:06.000Z","size":51,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-23T01:25:28.385Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cmdruid.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-11-15T20:35:39.000Z","updated_at":"2023-11-15T20:37:10.000Z","dependencies_parsed_at":"2024-04-18T12:12:06.557Z","dependency_job_id":"52d78dd2-e817-496e-9a69-b35c3e3c7db9","html_url":"https://github.com/cmdruid/break-vercel","commit_stats":null,"previous_names":["cmdruid/break-vercel"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cmdruid/break-vercel","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdruid%2Fbreak-vercel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdruid%2Fbreak-vercel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdruid%2Fbreak-vercel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdruid%2Fbreak-vercel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cmdruid","download_url":"https://codeload.github.com/cmdruid/break-vercel/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cmdruid%2Fbreak-vercel/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34680620,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-23T02:00:07.161Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-09T10:36:52.779Z","updated_at":"2026-06-23T07:31:45.610Z","avatar_url":"https://github.com/cmdruid.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# break vercel (cors)\n\nA simple web project to demonstrate some issues with vercel, CORS, and custom headers.\n\n## Setup\n\nInstall dependencies for server.\n\n`yarn install`\n\nInstall dependencies for client.\n\n`cd client \u0026\u0026 yarn install`\n\n## Overview\n\nThe `api` folder has a simple endpoint with a recommended cors middleware. This middleware was taken from the following url:\n\n[How can I enable CORS on Vercel?](https://vercel.com/guides/how-to-enable-cors)\n\nYou can start the vercel server using `vercel dev`.\n\n\u003e Note: Feel free to add / remove the cors middleware to demonstrate that it is working under normal conditions.\n\nThe `client` folder has a basic vite app that uses the `useSWR` package to fetch from the `api` endpoint.\n\nYou can start the client app using `cd client \u0026\u0026 yarn dev`\n\n## Issue\n\nThe issue appears to be when a custom key is used in the request header.\n\nTypically, the policy set in the `allowCors` middleware should take effect, however something within the vercel server appears to be rejecting the request before the middleware.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcmdruid%2Fbreak-vercel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcmdruid%2Fbreak-vercel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcmdruid%2Fbreak-vercel/lists"}