{"id":19010372,"url":"https://github.com/pcattori/remix-byoc-example","last_synced_at":"2025-10-29T10:25:46.975Z","repository":{"id":44963775,"uuid":"513177981","full_name":"pcattori/remix-byoc-example","owner":"pcattori","description":null,"archived":false,"fork":false,"pushed_at":"2022-09-01T15:39:03.000Z","size":729,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-17T14:38:26.165Z","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/pcattori.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}},"created_at":"2022-07-12T14:36:36.000Z","updated_at":"2024-12-02T11:51:01.000Z","dependencies_parsed_at":"2023-01-17T20:16:29.435Z","dependency_job_id":null,"html_url":"https://github.com/pcattori/remix-byoc-example","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pcattori%2Fremix-byoc-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pcattori%2Fremix-byoc-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pcattori%2Fremix-byoc-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pcattori%2Fremix-byoc-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pcattori","download_url":"https://codeload.github.com/pcattori/remix-byoc-example/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250338492,"owners_count":21414196,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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-08T19:11:00.297Z","updated_at":"2025-10-29T10:25:41.931Z","avatar_url":"https://github.com/pcattori.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Remix - Bring Your Own Compiler (BYOC)\n\nGoal: Let users customize build (e.g via plugins) to support the features they care about that are outside the scope for Remix.\n\nApp is copied from [kentcdodds/fakebooks-remix](https://github.com/kentcdodds/fakebooks-remix).\n\n## Build and run\n\n```sh\nnpm run byoc2\nnpm run start\n```\n\n## Technical approach\n\nNote: code in `./.remix/lib/` would eventually be imported from a Remix package like `@remix-run/dev` or similar.\n\nDefine compiler-agnostic function signatures for compiling the browser bundle and the server bundle:\n\n```ts\nimport type { AssetsManifest } from \"@remix-run/dev/compiler/assets\";\nimport type { RemixConfig } from \"@remix-run/dev/config\";\n\n/**\n * Compile the browser bundle.\n * Write compiled output to `./public/build/`\n */\nexport type CompileBrowser = (\n  remixConfig: RemixConfig\n) =\u003e Promise\u003cAssetsManifest\u003e;\n\n/**\n * Compile the server bundle.\n * Write compiled output to `./build/index.js`\n */\nexport type CompileServer = (\n  remixConfig: RemixConfig,\n  manifestPromise: Promise\u003cAssetsManifest\u003e\n) =\u003e Promise\u003cvoid\u003e;\n```\n\nThen provide a `build` function that accepts implementations for compiling browser and server:\n\n```ts\ntype Build = (\n  remixConfig: RemixConfig,\n  compile: { browser: CompileBrowser; server: CompileServer }\n) =\u003e [ReturnType\u003cCompileBrowser\u003e, ReturnType\u003cCompileServer\u003e];\n```\n\n## Conventions (TBD)\n\n```\nmy-remix-app/\n- .remix/\n  - compiler.mjs\n  - config.browser.js\n  - config.server.mjs\n```\n\n## TODO\n- [ ] Fix live reload\n- [ ] `dev`/`watch` mode\n- [ ] Refactor webpack configs into a Remix webpack plugin","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpcattori%2Fremix-byoc-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpcattori%2Fremix-byoc-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpcattori%2Fremix-byoc-example/lists"}