Skip to content

Commit

Permalink
Update Documentation to align with AlternativeLongMemberDefinitions (#…
Browse files Browse the repository at this point in the history
…1669)

fix: AlternativeLongMemberDefinitions changed in #1334 but were not reflected in documentation.

Closes: #1666
  • Loading branch information
rehael authored Apr 21, 2021
1 parent a955b71 commit 568d666
Showing 1 changed file with 28 additions and 4 deletions.
32 changes: 28 additions & 4 deletions docs/Documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -926,17 +926,30 @@ let run

### fsharp_alternative_long_member_definitions

Provides an alternative way of formatting long member and constructor definitions.
Provides an alternative way of formatting long member and constructor definitions,
where the difference is mainly in the equal sign and returned type placement.
Default = false.

`defaultConfig`

```fsharp
type C(aVeryLongType: AVeryLongTypeThatYouNeedToUse,
aSecondVeryLongType: AVeryLongTypeThatYouNeedToUse,
aThirdVeryLongType: AVeryLongTypeThatYouNeedToUse) =
type C
(
aVeryLongType: AVeryLongTypeThatYouNeedToUse,
aSecondVeryLongType: AVeryLongTypeThatYouNeedToUse,
aThirdVeryLongType: AVeryLongTypeThatYouNeedToUse
) =
class
end
type D() =
member _.LongMethodWithLotsOfParameters
(
aVeryLongParam: AVeryLongTypeThatYouNeedToUse,
aSecondVeryLongParam: AVeryLongTypeThatYouNeedToUse,
aThirdVeryLongParam: AVeryLongTypeThatYouNeedToUse
) : ReturnType =
42
```

`{ defaultConfig with AlternativeLongMemberDefinitions = true }`
Expand All @@ -951,6 +964,17 @@ type C
=
class
end
type D() =
member _.LongMethodWithLotsOfParameters
(
aVeryLongParam: AVeryLongTypeThatYouNeedToUse,
aSecondVeryLongParam: AVeryLongTypeThatYouNeedToUse,
aThirdVeryLongParam: AVeryLongTypeThatYouNeedToUse
)
: ReturnType
=
42
```

### fsharp_multi_line_lambda_closing_newline
Expand Down

0 comments on commit 568d666

Please sign in to comment.