dprint-plugin-typescript icon indicating copy to clipboard operation
dprint-plugin-typescript copied to clipboard

Support adding space before parenthesis in function call expressions

Open lorefnon opened this issue 3 years ago • 1 comments

Currently we have config options for "functionDeclaration.spaceBeforeParentheses", "functionExpression.spaceBeforeParentheses", etc. It would be good to have a similar "functionApplication.spaceBeforeParentheses".

This is useful for sanctuary style curried functions.

S.reduce (S.add) (0) (xs)

lorefnon avatar Jan 15 '23 07:01 lorefnon

👍

It would also be nice to allow:

S.reduce 
  (S.add)
  (0)
  (xs)

equivalent the following for non curried functions:

S.reduce(
  S.add,
  0,
  xs,
)

adrian-gierakowski avatar Jan 15 '23 09:01 adrian-gierakowski