Skip to content

Commit 48c7dca

Browse files
committed
Update docs
1 parent 0e1fe07 commit 48c7dca

File tree

1 file changed

+16
-27
lines changed

1 file changed

+16
-27
lines changed

README.md

Lines changed: 16 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -280,20 +280,21 @@ Here are some common formatting styles you can achieve by combining different op
280280

281281
```ts
282282
node.toString({
283-
array: {
284-
leadingIndentation: false, // keep arrays inline when short
285-
trailingComma: false,
286-
commaSpacing: true,
287-
},
288-
object: {
289-
leadingIndentation: true, // multi-line objects
290-
entryIndentation: true,
291-
trailingIndentation: true,
292-
indentationSize: 2,
293-
trailingComma: true,
294-
commaSpacing: true,
295-
colonSpacing: true,
296-
},
283+
array: {
284+
leadingIndentation: false, // keep arrays inline
285+
trailingIndentation: false,
286+
trailingComma: false,
287+
commaSpacing: true,
288+
},
289+
object: {
290+
entryIndentation: true, // multi-line objects
291+
leadingIndentation: true,
292+
trailingIndentation: true,
293+
indentationSize: 2,
294+
trailingComma: true,
295+
commaSpacing: true,
296+
colonSpacing: true,
297+
},
297298
});
298299
```
299300

@@ -348,19 +349,7 @@ Output style:
348349
##### 3) Strict compact style (no spaces after commas/colons)
349350

350351
```ts
351-
node.toString({
352-
array: {
353-
leadingIndentation: false,
354-
trailingComma: false,
355-
commaSpacing: false,
356-
},
357-
object: {
358-
leadingIndentation: false,
359-
trailingComma: false,
360-
commaSpacing: false,
361-
colonSpacing: false,
362-
},
363-
});
352+
node.toString();
364353
```
365354

366355
Output style:

0 commit comments

Comments
 (0)