Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add attributes rule option #367

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

trozware
Copy link

See issue #365

The SwiftLint attributes rule states "Attributes should be on their own lines in functions and types, but on the same line as variables and imports"

But it flags property wrapper lines like these with warnings, even though they are not functions or types:

@AppStorage("editorFontSize") var editorFontSize: Double = 14
@SceneStorage("windowTheme") var windowTheme = "dark"
@Environment(\.dismiss) var dismiss

Adding this option to the attributes rule solves this: attributes_with_arguments_always_on_line_above: false

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant