-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.swiftformat
More file actions
60 lines (46 loc) · 1.13 KB
/
.swiftformat
File metadata and controls
60 lines (46 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# SwiftFormat configuration for IONCameraLib
# Targets iOS 14+ / Swift 5.9+
--swiftversion 5.9
--minversion 0.54.0
# Indentation
--indent 4
--tabwidth 4
--smarttabs enabled
--indentcase false
# Line endings
--linebreaks lf
# Headers
--header strip
# Line length — matches SwiftLint warning threshold
--maxwidth 150
--wraparguments before-first
--wrapparameters before-first
--wrapcollections before-first
--closingparen balanced
--wrapreturntype if-multiline
# Imports
--importgrouping testable-last
# Self — remove redundant self outside init/deinit
--self init-only
# Trailing items
--semicolons never
--commas always
--trimwhitespace always
# Attributes
--funcattributes prev-line
--typeattributes prev-line
--varattributes same-line
# Closures & functions
--trailingclosures always
--nospaceoperators ..<,...
--operatorfunc spaced
# Braces
--guardelse auto
# Redundant syntax
--redundanttype inferred
--stripunusedargs closure-only
--patternlet inline
# Organise declarations (protocols, extensions, types)
--extensionacl on-declarations
# Disable rules that conflict with SwiftLint opt-in rules
--disable blankLinesAtStartOfScope