Skip to content

Commit bfd1d8d

Browse files
authored
Add $schema to Wrangler jsonc config (#26070)
1 parent 335ea35 commit bfd1d8d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/components/WranglerConfig.astro

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,10 @@ let toml, json;
3838
3939
if (language === "toml") {
4040
toml = code;
41-
json = JSON.stringify(TOML.parse(code), null, 2);
41+
json = JSON.stringify({
42+
"$schema": "./node_modules/wrangler/config-schema.json",
43+
...TOML.parse(code),
44+
}, null, 2);
4245
} else {
4346
json = code;
4447
toml = TOML.stringify(jsoncParse(code));

0 commit comments

Comments
 (0)