SwiftFormat icon indicating copy to clipboard operation
SwiftFormat copied to clipboard

A command-line tool and Xcode Extension for formatting Swift code

Results 181 SwiftFormat issues
Sort by recently updated
recently updated
newest added

At WWDC23 Apple is requiring all api calls that fall under this ruleset https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api#4278394 be added to a privacy manifest file. Does SwiftFormat need to include this manifest? Please let...

The following snippet causes `SwiftFormat` to break the code: ```swift func urlTestContains(path: String, strict _: Bool = true) -> Bool { let path = if path.hasSuffix("/") { path } else...

Related: https://github.com/nicklockwood/SwiftFormat/issues/849 Added an example syntax for the `modifiersOrder` option and separate section about default order by groups in the Rules.md doc.

I would like to have a new reporter to report as XML. Reports warnings as XML conforming to the Checkstyle specification, as defined here: https://www.jetbrains.com/help/teamcity/xml-report-processing.html I can try to write...

enhancement
fixed in develop

For a few months I'd run a `swiftformat` linting as part of my build to see whether I needed to manually format code (in order to avoid Xcode issues I...

Hi. I've just integrated your lovely tool into the build phrase as the final success step. However, I've noticed a rather weird behavior. Here's the original code snippet: ``` //...

bug
enhancement

# Description Swift 5.10 (Xcode 15.3) introduced the `nonisolated(unsafe)` keyword. In the following line the backticks are required: ```swift nonisolated(unsafe) let `self` = self ``` The `strongifiedSelf` rule strips these,...

can't reproduce

This one will be a longshot 🙃 This PR adds an ability to organize types by `type` rather than `visibility` (but its more like an attempt to make this rule...

When formatting the MainViewController.swift file after saving bookmarks, all bookmark information for MainViewController.swift gets corrupted. To be more specific, all bookmark information ends up pointing to the last line of...

Help, how can this be achieved? ```diff - List(...){...}.toolbar(content: { ... }) + List(...){...}.toolbar {...}