Contributing Examples
One of the objectives of Unibeautify is to provide an exceptional user experience regardless of languages or beautifiers involved. Examples play an integral role when demonstrating how configuring an option impacts the formatted code.
Note: You can see below the coverage of examples for each language and option. Click the ✎ icon below to add/edit an example.
Progress | # of Examples Completed | # of Examples Missing | # of Examples |
---|---|---|---|
234 | 112 | 346 |
# | Language | Progress | # of Examples | # of Options |
---|---|---|---|---|
1 | C | 0 | 0 | |
2 | C# | 9 | 9 | |
3 | C++ | 0 | 0 | |
4 | CSS | 13 | 13 | |
5 | ColdFusion | 7 | 7 | |
6 | EJS | 2 | 22 | |
7 | Go | 0 | 0 | |
8 | GraphQL | 5 | 5 | |
9 | HTML | 16 | 16 | |
10 | HTML+ERB | 7 | 7 | |
11 | Handlebars | 2 | 16 | |
12 | Haskell | 0 | 0 | |
13 | JSON | 4 | 4 | |
14 | JSON5 | 5 | 5 | |
15 | JSX | 29 | 29 | |
16 | Java | 9 | 9 | |
17 | JavaScript | 29 | 29 | |
18 | Less | 10 | 11 | |
19 | Liquid | 2 | 13 | |
20 | Markdown | 4 | 4 | |
21 | Mustache | 2 | 13 | |
22 | Objective-C | 0 | 0 | |
23 | PHP | 0 | 0 | |
24 | Python | 3 | 3 | |
25 | Riot | 2 | 11 | |
26 | SCSS | 10 | 11 | |
27 | SQL | 3 | 3 | |
28 | SVG | 2 | 7 | |
29 | Sass | 5 | 6 | |
30 | Spacebars | 2 | 7 | |
31 | SugarSS | 6 | 6 | |
32 | Swig | 0 | 11 | |
33 | Titanium Style Sheets | 2 | 7 | |
34 | Twig | 3 | 11 | |
35 | TypeScript | 17 | 17 | |
36 | Visualforce | 2 | 7 | |
37 | Vue | 4 | 4 | |
38 | XML | 16 | 16 | |
39 | XTemplate | 2 | 7 |
C
# | Option | Example | Edit |
---|
C#
# | Option | Example | Edit |
---|---|---|---|
1 | Align Assignments | ✅ | ✎ |
2 | Break Chained Methods | ✅ | ✎ |
3 | Indent Comments | ✅ | ✎ |
4 | Indent Size | ✅ | ✎ |
5 | Indent Style | ✅ | ✎ |
6 | Max Preserve Newlines | ✅ | ✎ |
7 | Multiline Ternary | ✅ | ✎ |
8 | Quotes | ✅ | ✎ |
9 | Wrap Line Length | ✅ | ✎ |
C++
# | Option | Example | Edit |
---|
CSS
# | Option | Example | Edit |
---|---|---|---|
1 | End With Newline | ✅ | ✎ |
2 | Indent Size | ✅ | ✎ |
3 | Indent Style | ✅ | ✎ |
4 | Max Preserve Newlines | ✅ | ✎ |
5 | Newline Between Rules | ✅ | ✎ |
6 | No Leading Zero | ✅ | ✎ |
7 | Pragma Insert | ✅ | ✎ |
8 | Pragma Require | ✅ | ✎ |
9 | Preserve Newlines | ✅ | ✎ |
10 | Quotes | ✅ | ✎ |
11 | Remove Trailing Whitespace | ✅ | ✎ |
12 | Selector Separator Newline | ✅ | ✎ |
13 | Wrap Line Length | ✅ | ✎ |
ColdFusion
# | Option | Example | Edit |
---|---|---|---|
1 | Force Indentation | ✅ | ✎ |
2 | Indent Comments | ✅ | ✎ |
3 | Indent Size | ✅ | ✎ |
4 | Indent Style | ✅ | ✎ |
5 | Max Preserve Newlines | ✅ | ✎ |
6 | Quotes | ✅ | ✎ |
7 | Wrap Line Length | ✅ | ✎ |
EJS
# | Option | Example | Edit |
---|---|---|---|
1 | Align Assignments | ❌ | ✎ |
2 | Brace Style | ❌ | ✎ |
3 | Break Chained Methods | ❌ | ✎ |
4 | Comma First | ❌ | ✎ |
5 | End With Comma | ❌ | ✎ |
6 | End With Newline | ❌ | ✎ |
7 | Indent Chained Methods | ❌ | ✎ |
8 | Indent Comments | ❌ | ✎ |
9 | Indent Size | ✅ | ✎ |
10 | Indent Style | ✅ | ✎ |
11 | JSLint Happy | ❌ | ✎ |
12 | Keep Array Indentation | ❌ | ✎ |
13 | Max Preserve Newlines | ❌ | ✎ |
14 | Multiline Ternary | ❌ | ✎ |
15 | Preserve Newlines | ❌ | ✎ |
16 | Quotes | ❌ | ✎ |
17 | Space After Anon Function | ❌ | ✎ |
18 | Space Before Conditional | ❌ | ✎ |
19 | Space In Empty Paren | ❌ | ✎ |
20 | Space In Paren | ❌ | ✎ |
21 | Unescape Strings | ❌ | ✎ |
22 | Wrap Line Length | ❌ | ✎ |
Go
# | Option | Example | Edit |
---|
GraphQL
# | Option | Example | Edit |
---|---|---|---|
1 | Indent Size | ✅ | ✎ |
2 | Indent Style | ✅ | ✎ |
3 | Pragma Insert | ✅ | ✎ |
4 | Pragma Require | ✅ | ✎ |
5 | Wrap Line Length | ✅ | ✎ |
HTML
# | Option | Example | Edit |
---|---|---|---|
1 | Brace Style | ✅ | ✎ |
2 | End With Newline | ✅ | ✎ |
3 | Force Indentation | ✅ | ✎ |
4 | Indent Comments | ✅ | ✎ |
5 | Indent Inner Html | ✅ | ✎ |
6 | Indent Scripts | ✅ | ✎ |
7 | Indent Size | ✅ | ✎ |
8 | Indent Style | ✅ | ✎ |
9 | Max Preserve Newlines | ✅ | ✎ |
10 | Newline Before Tags | ✅ | ✎ |
11 | Preserve Newlines | ✅ | ✎ |
12 | Quotes | ✅ | ✎ |
13 | Unformatted | ✅ | ✎ |
14 | Wrap Attributes | ✅ | ✎ |
15 | Wrap Attributes Indent Size | ✅ | ✎ |
16 | Wrap Line Length | ✅ | ✎ |
HTML+ERB
# | Option | Example | Edit |
---|---|---|---|
1 | Force Indentation | ✅ | ✎ |
2 | Indent Comments | ✅ | ✎ |
3 | Indent Size | ✅ | ✎ |
4 | Indent Style | ✅ | ✎ |
5 | Max Preserve Newlines | ✅ | ✎ |
6 | Quotes | ✅ | ✎ |
7 | Wrap Line Length | ✅ | ✎ |
Handlebars
# | Option | Example | Edit |
---|---|---|---|
1 | Brace Style | ❌ | ✎ |
2 | End With Newline | ❌ | ✎ |
3 | Force Indentation | ❌ | ✎ |
4 | Indent Comments | ❌ | ✎ |
5 | Indent Inner Html | ❌ | ✎ |
6 | Indent Scripts | ❌ | ✎ |
7 | Indent Size | ✅ | ✎ |
8 | Indent Style | ✅ | ✎ |
9 | Max Preserve Newlines | ❌ | ✎ |
10 | Newline Before Tags | ❌ | ✎ |
11 | Preserve Newlines | ❌ | ✎ |
12 | Quotes | ❌ | ✎ |
13 | Unformatted | ❌ | ✎ |
14 | Wrap Attributes | ❌ | ✎ |
15 | Wrap Attributes Indent Size | ❌ | ✎ |
16 | Wrap Line Length | ❌ | ✎ |
Haskell
# | Option | Example | Edit |
---|
JSON
# | Option | Example | Edit |
---|---|---|---|
1 | Indent Size | ✅ | ✎ |
2 | Indent Style | ✅ | ✎ |
3 | Max Preserve Newlines | ✅ | ✎ |
4 | Quotes | ✅ | ✎ |
JSON5
# | Option | Example | Edit |
---|---|---|---|
1 | Indent Comments | ✅ | ✎ |
2 | Indent Size | ✅ | ✎ |
3 | Indent Style | ✅ | ✎ |
4 | Max Preserve Newlines | ✅ | ✎ |
5 | Quotes | ✅ | ✎ |
JSX
Java
# | Option | Example | Edit |
---|---|---|---|
1 | Align Assignments | ✅ | ✎ |
2 | Break Chained Methods | ✅ | ✎ |
3 | Indent Comments | ✅ | ✎ |
4 | Indent Size | ✅ | ✎ |
5 | Indent Style | ✅ | ✎ |
6 | Max Preserve Newlines | ✅ | ✎ |
7 | Multiline Ternary | ✅ | ✎ |
8 | Quotes | ✅ | ✎ |
9 | Wrap Line Length | ✅ | ✎ |
JavaScript
Less
# | Option | Example | Edit |
---|---|---|---|
1 | End With Newline | ❌ | ✎ |
2 | Indent Size | ✅ | ✎ |
3 | Indent Style | ✅ | ✎ |
4 | Max Preserve Newlines | ✅ | ✎ |
5 | Newline Between Rules | ✅ | ✎ |
6 | No Leading Zero | ✅ | ✎ |
7 | Pragma Insert | ✅ | ✎ |
8 | Pragma Require | ✅ | ✎ |
9 | Quotes | ✅ | ✎ |
10 | Remove Trailing Whitespace | ✅ | ✎ |
11 | Wrap Line Length | ✅ | ✎ |
Liquid
# | Option | Example | Edit |
---|---|---|---|
1 | Brace Style | ❌ | ✎ |
2 | End With Newline | ❌ | ✎ |
3 | Indent Inner Html | ❌ | ✎ |
4 | Indent Scripts | ❌ | ✎ |
5 | Indent Size | ✅ | ✎ |
6 | Indent Style | ✅ | ✎ |
7 | Max Preserve Newlines | ❌ | ✎ |
8 | Newline Before Tags | ❌ | ✎ |
9 | Preserve Newlines | ❌ | ✎ |
10 | Unformatted | ❌ | ✎ |
11 | Wrap Attributes | ❌ | ✎ |
12 | Wrap Attributes Indent Size | ❌ | ✎ |
13 | Wrap Line Length | ❌ | ✎ |
Markdown
# | Option | Example | Edit |
---|---|---|---|
1 | Pragma Insert | ✅ | ✎ |
2 | Pragma Require | ✅ | ✎ |
3 | Wrap Line Length | ✅ | ✎ |
4 | Wrap Prose | ✅ | ✎ |
Mustache
# | Option | Example | Edit |
---|---|---|---|
1 | Brace Style | ❌ | ✎ |
2 | End With Newline | ❌ | ✎ |
3 | Indent Inner Html | ❌ | ✎ |
4 | Indent Scripts | ❌ | ✎ |
5 | Indent Size | ✅ | ✎ |
6 | Indent Style | ✅ | ✎ |
7 | Max Preserve Newlines | ❌ | ✎ |
8 | Newline Before Tags | ❌ | ✎ |
9 | Preserve Newlines | ❌ | ✎ |
10 | Unformatted | ❌ | ✎ |
11 | Wrap Attributes | ❌ | ✎ |
12 | Wrap Attributes Indent Size | ❌ | ✎ |
13 | Wrap Line Length | ❌ | ✎ |
Objective-C
# | Option | Example | Edit |
---|
PHP
# | Option | Example | Edit |
---|
Python
# | Option | Example | Edit |
---|---|---|---|
1 | Indent Size | ✅ | ✎ |
2 | Indent Style | ✅ | ✎ |
3 | Wrap Line Length | ✅ | ✎ |
Riot
# | Option | Example | Edit |
---|---|---|---|
1 | Align Assignments | ❌ | ✎ |
2 | Break Chained Methods | ❌ | ✎ |
3 | End With Comma | ❌ | ✎ |
4 | Indent Comments | ❌ | ✎ |
5 | Indent Size | ✅ | ✎ |
6 | Indent Style | ✅ | ✎ |
7 | Max Preserve Newlines | ❌ | ✎ |
8 | Multiline Ternary | ❌ | ✎ |
9 | Quotes | ❌ | ✎ |
10 | Space After Anon Function | ❌ | ✎ |
11 | Wrap Line Length | ❌ | ✎ |
SCSS
# | Option | Example | Edit |
---|---|---|---|
1 | End With Newline | ❌ | ✎ |
2 | Indent Size | ✅ | ✎ |
3 | Indent Style | ✅ | ✎ |
4 | Max Preserve Newlines | ✅ | ✎ |
5 | Newline Between Rules | ✅ | ✎ |
6 | No Leading Zero | ✅ | ✎ |
7 | Pragma Insert | ✅ | ✎ |
8 | Pragma Require | ✅ | ✎ |
9 | Quotes | ✅ | ✎ |
10 | Remove Trailing Whitespace | ✅ | ✎ |
11 | Wrap Line Length | ✅ | ✎ |
SQL
# | Option | Example | Edit |
---|---|---|---|
1 | Identifier Case | ✅ | ✎ |
2 | Indent Size | ✅ | ✎ |
3 | Keyword Case | ✅ | ✎ |
SVG
# | Option | Example | Edit |
---|---|---|---|
1 | Force Indentation | ❌ | ✎ |
2 | Indent Comments | ❌ | ✎ |
3 | Indent Size | ✅ | ✎ |
4 | Indent Style | ✅ | ✎ |
5 | Max Preserve Newlines | ❌ | ✎ |
6 | Quotes | ❌ | ✎ |
7 | Wrap Line Length | ❌ | ✎ |
Sass
# | Option | Example | Edit |
---|---|---|---|
1 | End With Newline | ❌ | ✎ |
2 | Indent Size | ✅ | ✎ |
3 | Indent Style | ✅ | ✎ |
4 | Quotes | ✅ | ✎ |
5 | Remove Trailing Whitespace | ✅ | ✎ |
6 | Wrap Line Length | ✅ | ✎ |
Spacebars
# | Option | Example | Edit |
---|---|---|---|
1 | Force Indentation | ❌ | ✎ |
2 | Indent Comments | ❌ | ✎ |
3 | Indent Size | ✅ | ✎ |
4 | Indent Style | ✅ | ✎ |
5 | Max Preserve Newlines | ❌ | ✎ |
6 | Quotes | ❌ | ✎ |
7 | Wrap Line Length | ❌ | ✎ |
SugarSS
# | Option | Example | Edit |
---|---|---|---|
1 | End With Newline | ✅ | ✎ |
2 | Indent Size | ✅ | ✎ |
3 | Indent Style | ✅ | ✎ |
4 | Quotes | ✅ | ✎ |
5 | Remove Trailing Whitespace | ✅ | ✎ |
6 | Wrap Line Length | ✅ | ✎ |
Swig
# | Option | Example | Edit |
---|---|---|---|
1 | Align Assignments | ❌ | ✎ |
2 | Break Chained Methods | ❌ | ✎ |
3 | End With Comma | ❌ | ✎ |
4 | Indent Comments | ❌ | ✎ |
5 | Indent Size | ❌ | ✎ |
6 | Indent Style | ❌ | ✎ |
7 | Max Preserve Newlines | ❌ | ✎ |
8 | Multiline Ternary | ❌ | ✎ |
9 | Quotes | ❌ | ✎ |
10 | Space After Anon Function | ❌ | ✎ |
11 | Wrap Line Length | ❌ | ✎ |
Titanium Style Sheets
# | Option | Example | Edit |
---|---|---|---|
1 | Indent Size | ✅ | ✎ |
2 | Indent Style | ✅ | ✎ |
3 | Max Preserve Newlines | ❌ | ✎ |
4 | Newline Between Rules | ❌ | ✎ |
5 | No Leading Zero | ❌ | ✎ |
6 | Quotes | ❌ | ✎ |
7 | Wrap Line Length | ❌ | ✎ |
Twig
# | Option | Example | Edit |
---|---|---|---|
1 | Align Assignments | ❌ | ✎ |
2 | Break Chained Methods | ❌ | ✎ |
3 | End With Comma | ❌ | ✎ |
4 | Indent Comments | ❌ | ✎ |
5 | Indent Size | ✅ | ✎ |
6 | Indent Style | ✅ | ✎ |
7 | Max Preserve Newlines | ❌ | ✎ |
8 | Multiline Ternary | ❌ | ✎ |
9 | Quotes | ✅ | ✎ |
10 | Space After Anon Function | ❌ | ✎ |
11 | Wrap Line Length | ❌ | ✎ |
TypeScript
# | Option | Example | Edit |
---|---|---|---|
1 | Align Assignments | ✅ | ✎ |
2 | Arrow Parens | ✅ | ✎ |
3 | Break Chained Methods | ✅ | ✎ |
4 | End With Comma | ✅ | ✎ |
5 | End With Semicolon | ✅ | ✎ |
6 | Indent Comments | ✅ | ✎ |
7 | Indent Size | ✅ | ✎ |
8 | Indent Style | ✅ | ✎ |
9 | JSX Brackets | ✅ | ✎ |
10 | Max Preserve Newlines | ✅ | ✎ |
11 | Multiline Ternary | ✅ | ✎ |
12 | Object Curly Spacing | ✅ | ✎ |
13 | Pragma Insert | ✅ | ✎ |
14 | Pragma Require | ✅ | ✎ |
15 | Quotes | ✅ | ✎ |
16 | Space After Anon Function | ✅ | ✎ |
17 | Wrap Line Length | ✅ | ✎ |
Visualforce
# | Option | Example | Edit |
---|---|---|---|
1 | Force Indentation | ❌ | ✎ |
2 | Indent Comments | ❌ | ✎ |
3 | Indent Size | ✅ | ✎ |
4 | Indent Style | ✅ | ✎ |
5 | Max Preserve Newlines | ❌ | ✎ |
6 | Quotes | ❌ | ✎ |
7 | Wrap Line Length | ❌ | ✎ |
Vue
# | Option | Example | Edit |
---|---|---|---|
1 | Indent Size | ✅ | ✎ |
2 | Indent Style | ✅ | ✎ |
3 | Pragma Insert | ✅ | ✎ |
4 | Pragma Require | ✅ | ✎ |
XML
# | Option | Example | Edit |
---|---|---|---|
1 | Brace Style | ✅ | ✎ |
2 | End With Newline | ✅ | ✎ |
3 | Force Indentation | ✅ | ✎ |
4 | Indent Comments | ✅ | ✎ |
5 | Indent Inner Html | ✅ | ✎ |
6 | Indent Scripts | ✅ | ✎ |
7 | Indent Size | ✅ | ✎ |
8 | Indent Style | ✅ | ✎ |
9 | Max Preserve Newlines | ✅ | ✎ |
10 | Newline Before Tags | ✅ | ✎ |
11 | Preserve Newlines | ✅ | ✎ |
12 | Quotes | ✅ | ✎ |
13 | Unformatted | ✅ | ✎ |
14 | Wrap Attributes | ✅ | ✎ |
15 | Wrap Attributes Indent Size | ✅ | ✎ |
16 | Wrap Line Length | ✅ | ✎ |
XTemplate
# | Option | Example | Edit |
---|---|---|---|
1 | Force Indentation | ❌ | ✎ |
2 | Indent Comments | ❌ | ✎ |
3 | Indent Size | ✅ | ✎ |
4 | Indent Style | ✅ | ✎ |
5 | Max Preserve Newlines | ❌ | ✎ |
6 | Quotes | ❌ | ✎ |
7 | Wrap Line Length | ❌ | ✎ |