elm-format inspired prettier to let the user branch between two different formatters without the use of explicit options, by taking cues from the source's original formatting. (see multi-line objects)
- Context: an object literal is sometimes better displayed on multiple lines even it can fit on one
- Problem: it was deemed impossible for the formatter to know when multiline is preferable
- Solution: allow the user to insert a newline after the first curly to force multiline
// before
const a = {foo:1, bar:2}; // <-- no newline after curly allows default formatting
// after
const a = { foo: 1, bar: 2 };
// before
const a = { // <-- newline after the curly forces MULTILINE formatting
foo:1, bar:2};
// after:
const a = {
foo:1,
bar:2
};