|
| 1 | +[ |
| 2 | + { |
| 3 | + "url": "https://api.github.com/repos/yamcodes/arkenv/pulls/comments/3443631309", |
| 4 | + "pull_request_review_id": 4534203043, |
| 5 | + "id": 3443631309, |
| 6 | + "node_id": "PRRC_kwDONvYw487NQaTN", |
| 7 | + "diff_hunk": "@@ -220,10 +235,20 @@ export function createEnvInternal(\n \t\t}\n \t}\n \n+\tconst globalEnv =\n+\t\ttypeof globalThis !== \"undefined\"\n+\t\t\t? (globalThis as any).__arkenv_env__\n+\t\t\t: undefined;\n+\n \tfor (const key of Object.keys(runtimeEnv)) {\n \t\tif (runtimeEnv[key] !== undefined) {\n \t\t\tcombinedEnv[key] = runtimeEnv[key];\n \t\t}\n+\t\tif (globalEnv && globalEnv[key] !== undefined) {", |
| 8 | + "path": "packages/nextjs/src/create-env.ts", |
| 9 | + "commit_id": "76b99f8d62c50553839deaa1d21c378fdcf4d6e7", |
| 10 | + "original_commit_id": "76b99f8d62c50553839deaa1d21c378fdcf4d6e7", |
| 11 | + "user": { |
| 12 | + "login": "pullfrog[bot]", |
| 13 | + "id": 226033991, |
| 14 | + "node_id": "BOT_kgDODXkBRw", |
| 15 | + "avatar_url": "https://avatars.githubusercontent.com/in/1768019?v=4", |
| 16 | + "gravatar_id": "", |
| 17 | + "url": "https://api.github.com/users/pullfrog%5Bbot%5D", |
| 18 | + "html_url": "https://github.com/apps/pullfrog", |
| 19 | + "followers_url": "https://api.github.com/users/pullfrog%5Bbot%5D/followers", |
| 20 | + "following_url": "https://api.github.com/users/pullfrog%5Bbot%5D/following{/other_user}", |
| 21 | + "gists_url": "https://api.github.com/users/pullfrog%5Bbot%5D/gists{/gist_id}", |
| 22 | + "starred_url": "https://api.github.com/users/pullfrog%5Bbot%5D/starred{/owner}{/repo}", |
| 23 | + "subscriptions_url": "https://api.github.com/users/pullfrog%5Bbot%5D/subscriptions", |
| 24 | + "organizations_url": "https://api.github.com/users/pullfrog%5Bbot%5D/orgs", |
| 25 | + "repos_url": "https://api.github.com/users/pullfrog%5Bbot%5D/repos", |
| 26 | + "events_url": "https://api.github.com/users/pullfrog%5Bbot%5D/events{/privacy}", |
| 27 | + "received_events_url": "https://api.github.com/users/pullfrog%5Bbot%5D/received_events", |
| 28 | + "type": "Bot", |
| 29 | + "user_view_type": "public", |
| 30 | + "site_admin": false |
| 31 | + }, |
| 32 | + "body": "ℹ️ `globalThis.__arkenv_env__` values are applied in `createEnvInternal` (here) AND already embedded in the generated `runtimeEnv` template strings (e.g. `typeof window !== \"undefined\" ? (globalThis as any).__arkenv_env__?.${key} ?? process.env.${key} : process.env.${key}`). This means `__arkenv_env__` values are written into `combinedEnv` twice — once via the resolved `runtimeEnv` value and once directly from `globalEnv`. The result is the same value written twice, so it's harmless, but worth noting the double path exists.", |
| 33 | + "created_at": "2026-06-19T16:27:41Z", |
| 34 | + "updated_at": "2026-06-19T16:27:42Z", |
| 35 | + "html_url": "https://github.com/yamcodes/arkenv/pull/1218#discussion_r3443631309", |
| 36 | + "pull_request_url": "https://api.github.com/repos/yamcodes/arkenv/pulls/1218", |
| 37 | + "_links": { |
| 38 | + "self": { |
| 39 | + "href": "https://api.github.com/repos/yamcodes/arkenv/pulls/comments/3443631309" |
| 40 | + }, |
| 41 | + "html": { |
| 42 | + "href": "https://github.com/yamcodes/arkenv/pull/1218#discussion_r3443631309" |
| 43 | + }, |
| 44 | + "pull_request": { |
| 45 | + "href": "https://api.github.com/repos/yamcodes/arkenv/pulls/1218" |
| 46 | + } |
| 47 | + }, |
| 48 | + "reactions": { |
| 49 | + "url": "https://api.github.com/repos/yamcodes/arkenv/pulls/comments/3443631309/reactions", |
| 50 | + "total_count": 0, |
| 51 | + "+1": 0, |
| 52 | + "-1": 0, |
| 53 | + "laugh": 0, |
| 54 | + "hooray": 0, |
| 55 | + "confused": 0, |
| 56 | + "heart": 0, |
| 57 | + "rocket": 0, |
| 58 | + "eyes": 0 |
| 59 | + }, |
| 60 | + "start_line": null, |
| 61 | + "original_start_line": null, |
| 62 | + "start_side": null, |
| 63 | + "line": 247, |
| 64 | + "original_line": 247, |
| 65 | + "side": "RIGHT", |
| 66 | + "author_association": "CONTRIBUTOR", |
| 67 | + "original_position": 50, |
| 68 | + "position": 50, |
| 69 | + "subject_type": "line" |
| 70 | + }, |
| 71 | + { |
| 72 | + "url": "https://api.github.com/repos/yamcodes/arkenv/pulls/comments/3443642776", |
| 73 | + "pull_request_review_id": 4534215833, |
| 74 | + "id": 3443642776, |
| 75 | + "node_id": "PRRC_kwDONvYw487NQdGY", |
| 76 | + "diff_hunk": "@@ -0,0 +1,25 @@\n+---\n+\"@arkenv/nextjs\": patch\n+\"@arkenv/cli\": patch\n+---\n+\n+#### Add Flat Layout Mode for Next.js integration\n+\n+Introduce a new \"Flat\" layout mode for `@arkenv/nextjs`. The Flat API allows developers to define a flat schema mapping directly to their `.env` file structure:\n+\n+```ts\n+import arkenv from \"./generated/env.gen\";\n+\n+export const env = arkenv({\n+\tDATABASE_URL: \"string\",\n+\tNEXT_PUBLIC_API_URL: \"string\",\n+\tNODE_ENV: \"'development' | 'production' | 'test' = 'development'\",\n+}, {\n+\tshared: [\"NODE_ENV\"]\n+});", |
| 77 | + "path": ".changeset/flat-layout-mode.md", |
| 78 | + "commit_id": "76b99f8d62c50553839deaa1d21c378fdcf4d6e7", |
| 79 | + "original_commit_id": "76b99f8d62c50553839deaa1d21c378fdcf4d6e7", |
| 80 | + "user": { |
| 81 | + "login": "yamcodes", |
| 82 | + "id": 2014360, |
| 83 | + "node_id": "MDQ6VXNlcjIwMTQzNjA=", |
| 84 | + "avatar_url": "https://avatars.githubusercontent.com/u/2014360?v=4", |
| 85 | + "gravatar_id": "", |
| 86 | + "url": "https://api.github.com/users/yamcodes", |
| 87 | + "html_url": "https://github.com/yamcodes", |
| 88 | + "followers_url": "https://api.github.com/users/yamcodes/followers", |
| 89 | + "following_url": "https://api.github.com/users/yamcodes/following{/other_user}", |
| 90 | + "gists_url": "https://api.github.com/users/yamcodes/gists{/gist_id}", |
| 91 | + "starred_url": "https://api.github.com/users/yamcodes/starred{/owner}{/repo}", |
| 92 | + "subscriptions_url": "https://api.github.com/users/yamcodes/subscriptions", |
| 93 | + "organizations_url": "https://api.github.com/users/yamcodes/orgs", |
| 94 | + "repos_url": "https://api.github.com/users/yamcodes/repos", |
| 95 | + "events_url": "https://api.github.com/users/yamcodes/events{/privacy}", |
| 96 | + "received_events_url": "https://api.github.com/users/yamcodes/received_events", |
| 97 | + "type": "User", |
| 98 | + "user_view_type": "public", |
| 99 | + "site_admin": false |
| 100 | + }, |
| 101 | + "body": "doubting we even need `shared` now, thoughts ? ", |
| 102 | + "created_at": "2026-06-19T16:30:56Z", |
| 103 | + "updated_at": "2026-06-19T16:30:56Z", |
| 104 | + "html_url": "https://github.com/yamcodes/arkenv/pull/1218#discussion_r3443642776", |
| 105 | + "pull_request_url": "https://api.github.com/repos/yamcodes/arkenv/pulls/1218", |
| 106 | + "_links": { |
| 107 | + "self": { |
| 108 | + "href": "https://api.github.com/repos/yamcodes/arkenv/pulls/comments/3443642776" |
| 109 | + }, |
| 110 | + "html": { |
| 111 | + "href": "https://github.com/yamcodes/arkenv/pull/1218#discussion_r3443642776" |
| 112 | + }, |
| 113 | + "pull_request": { |
| 114 | + "href": "https://api.github.com/repos/yamcodes/arkenv/pulls/1218" |
| 115 | + } |
| 116 | + }, |
| 117 | + "reactions": { |
| 118 | + "url": "https://api.github.com/repos/yamcodes/arkenv/pulls/comments/3443642776/reactions", |
| 119 | + "total_count": 0, |
| 120 | + "+1": 0, |
| 121 | + "-1": 0, |
| 122 | + "laugh": 0, |
| 123 | + "hooray": 0, |
| 124 | + "confused": 0, |
| 125 | + "heart": 0, |
| 126 | + "rocket": 0, |
| 127 | + "eyes": 0 |
| 128 | + }, |
| 129 | + "start_line": 17, |
| 130 | + "original_start_line": 17, |
| 131 | + "start_side": "RIGHT", |
| 132 | + "line": 19, |
| 133 | + "original_line": 19, |
| 134 | + "side": "RIGHT", |
| 135 | + "author_association": "OWNER", |
| 136 | + "original_position": 19, |
| 137 | + "position": 19, |
| 138 | + "subject_type": "line" |
| 139 | + } |
| 140 | +] |
0 commit comments