Skip to content

IniValueOptions

IniValueOptions = object

Defined in: packages/format-ini/src/parse.ts:11

How a syntax tree is projected onto a plain object.

readonly optional dottedKeys?: boolean

Defined in: packages/format-ini/src/parse.ts:30

Whether a dotted key or section name nests (a.b = 1 → {a: {b: 1}}).

Off by default: a dot is an ordinary key character in most INI files, and splitting on it silently rewrites keys that contain one.


readonly optional duplicateKeys?: "last" | "first" | "array"

Defined in: packages/format-ini/src/parse.ts:22

What a repeated key within one section means.

  • "last" (default) — later wins, the common configuration-file reading.
  • "first" — earlier wins.
  • "array" — every occurrence is collected, in order.

There is no right answer in general, which is why it is an option rather than a rule: git config multi-values, php.ini overwrites.