Do not use this project, I’ve abandoned it.
This is a simple JSON editing mode for Emacs.
- Folding of Objects and Arrays (
C-c C-fto toggle next one,C-c C-uto unfold everything) - Pretty printing files (
C-c C-p) (by default when file is opened as well,json-mode-pretty-print-on-opencan be set tonilto disable this) - Minification (
C-c C-m) - Idle time validation with result displayed on mode line
- Validation (
C-c C-v) - Get a path to value at point (
C-c C-l) in following formats- JavaScript notation (default)
- bracket notation
- JSON pointer (RFC 6091)
The easiest way to install this mode is to simply put it somewhere in load-path and add
(require 'json-mode)to your init file.
Files with .json extension will be opened with this mode by default.
This mode has autoload comments, so it should work nicely with lazy loading setups.
- Pretty printing and minifying replaces
{}withnull
