mirror of
https://github.com/neovim/neovim.git
synced 2025-09-17 00:38:17 +00:00

Problem: There is no way to ensure a stable key order when encoding a JSON string, which can be useful for comparisons and producing cleaner diffs. Solution: Introduce a `sort_keys` option for `vim.json.encode()`,which is disabled by default. When enabled, object keys are sorted in alphabetical order.