File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 88
99Fresh uses layered configuration.
1010
11+ ## Config File Format
12+
13+ Config files are ** JSONC** — standard JSON plus two conveniences:
14+
15+ - ** Comments** — ` // line ` and ` /* block */ `
16+ - ** Trailing commas** — a comma after the last entry in an object or array is fine
17+
18+ ``` jsonc
19+ {
20+ " theme" : " builtin://dracula" ,
21+ " editor" : {
22+ // tweak as needed
23+ " tab_size" : 2 ,
24+ " line_wrap" : true , // trailing comma below is OK
25+ },
26+ }
27+ ```
28+
29+ The parser is also lenient about small slips — a missing comma between entries
30+ or an unquoted key is tolerated — so a stray mistake won't silently reset you to
31+ defaults. Don't rely on that as a style; keep your config valid JSONC. An empty
32+ or comment-only file is treated as "no overrides".
33+
34+ A genuinely broken file (e.g. an unterminated object) does fail to parse. On
35+ ** save** , Fresh refuses to overwrite an unparseable file and surfaces the error
36+ rather than clobbering your settings.
37+
1138## Configuration Layers
1239
1340Settings are loaded from multiple layers, with higher layers overriding lower ones:
You can’t perform that action at this time.
0 commit comments