Skip to content
This repository was archived by the owner on Oct 24, 2023. It is now read-only.
This repository was archived by the owner on Oct 24, 2023. It is now read-only.

Whitespace with new fast pipes? #93

Description

@Anahkiasen

I updated refmt to 3.3.3 and it modified one my blocks in the following way

-  expenditure
-  |. getExpenditureAccounts
-  |. Belt.List.fromArray
-  |. Belt.List.getBy(id => id == accountId)
-  |. Option.isSome;
+  expenditure->getExpenditureAccounts->Belt.List.fromArray->(Belt.List.getBy(id => id == accountId))->Option.isSome;

Now I'm aware of the change from |. to -> but does the whitespace need to be discarded around the operator for it to work? I don't particularly find the updated code easier to read, quite the opposite :/

Could it not simply reformat it to this?

expenditure
-> getExpenditureAccounts
-> Belt.List.fromArray
-> Belt.List.getBy(id => id == accountId)
-> Option.isSome;

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions