{"id":20672374,"url":"https://github.com/andrewbrey/remix-curl","last_synced_at":"2026-04-19T14:32:02.932Z","repository":{"id":113435432,"uuid":"478294307","full_name":"andrewbrey/remix-curl","owner":"andrewbrey","description":"A demo of using Remix to send different responses depending on if the client is a browser or curl","archived":false,"fork":false,"pushed_at":"2022-04-06T00:26:32.000Z","size":191,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-13T01:06:09.279Z","etag":null,"topics":["curl","demo","remix","remix-run","vercel"],"latest_commit_sha":null,"homepage":"https://remix-curl.vercel.app/","language":"TypeScript","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/andrewbrey.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"publiccode":null,"codemeta":null}},"created_at":"2022-04-05T20:43:31.000Z","updated_at":"2023-03-04T18:19:40.000Z","dependencies_parsed_at":null,"dependency_job_id":"d195a2e6-09c6-43de-a2dc-9d591ae9f4b6","html_url":"https://github.com/andrewbrey/remix-curl","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/andrewbrey/remix-curl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewbrey%2Fremix-curl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewbrey%2Fremix-curl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewbrey%2Fremix-curl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewbrey%2Fremix-curl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/andrewbrey","download_url":"https://codeload.github.com/andrewbrey/remix-curl/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewbrey%2Fremix-curl/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32009841,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T20:23:30.271Z","status":"online","status_checked_at":"2026-04-19T02:00:07.110Z","response_time":55,"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":["curl","demo","remix","remix-run","vercel"],"created_at":"2024-11-16T20:33:55.214Z","updated_at":"2026-04-19T14:32:02.907Z","avatar_url":"https://github.com/andrewbrey.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Remix Curl Demo\n\nThis is demo of how you can use the fact that Remix provides you with a real server to send one response to web browsers and another response to a `curl` client.\n\n## Demo\n\nThis demo is deployed to `Vercel` and can be viewed in a web browser at https://remix-curl.vercel.app/\n\nAlternatively, you can curl this same url with:\n\n```bash\ncurl --silent https://remix-curl.vercel.app\n```\n\nto see how this site sends a _completely different_ response to `curl`, and in fact, the response to `curl` takes advantage of the fact that it's being called from a terminal and the plaintext response includes ansi style escape codes so that you get a pretty output in the terminal just like you do in the browser!\n\n### Notes\n\n- As of this writing (April 5th, 2022), Remix doesn't support configuring `esbuild` with custom `external` modules (may be fixed if they merge https://github.com/remix-run/remix/pull/1841). Unfortunately in addition to this, the `external` modules declared _internally_ by Remix are the Node built-ins (`process`, `fs`, etc) but _only_ those without the `node:` specifier prefix, which means any 3rd party dependency that references e.g. `node:process` (or any other Node built-in via its `node:` prefixed specifier) will cause a build error.\n\n  Since I wanted to use the [boxen module](https://github.com/sindresorhus/boxen) by @sindresorhus in the `curl` response text, and this module references `node:process`, I needed to use `patch-package` as a quick way to ensure that the un-prefixed Node built-in was being referenced by `boxen`.\n\n  If at some point either:\n\n  - Remix includes _both_ `node:` prefixed and unprefixed Node built-ins in their list of `external` modules for `esbuild`, OR\n  - Remix allows users to supply their own `external` module list via configuration\n\n  then this use of `patch-package` can go away.\n\n### See Also\n\nhttps://blog.andrewbrey.com/2022-04-05-building-a-curl-able-developer-resume-site-with-remix\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandrewbrey%2Fremix-curl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandrewbrey%2Fremix-curl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandrewbrey%2Fremix-curl/lists"}