From chapter 12, Type Feng Shui section, I have only changed line 4 from
sequence(Either.of, [Either.of('wing')]); // Right(['wing'])
to
sequence(List.of, Either.of(['wing'])), // List(Right('wing')),
which unlike the original will not throw a TypeError. But also is an example of inverting a Right (List (String)) to a List (Right (String)).
The original, Right (List (String)) to Right (List (String)) made little sense.
Line 5, however is not changed and does not highlight anything particular useful, since
sequence(Task.of, left('wing')) = Task.of(left('wing')).
This PR fixes most of the issues in #581.
From chapter 12, Type Feng Shui section, I have only changed line 4 from
sequence(Either.of, [Either.of('wing')]); // Right(['wing'])
tosequence(List.of, Either.of(['wing'])), // List(Right('wing'))
, which unlike the original will not throw a TypeError. But also is an example of inverting aRight (List (String))
to aList (Right (String))
. The original,Right (List (String))
toRight (List (String))
made little sense.Line 5, however is not changed and does not highlight anything particular useful, since
sequence(Task.of, left('wing'))
=Task.of(left('wing'))
.Only two changes was required to support/index.js.
Right
Map