If I dont use a separate function TypeScript can easily infer the function parameters and can effectively use the result of processFn to declare the Result
I think when the switch statment is executed the kind of a and the kind of b are always equal So when the kind of a is 1 the type of b will be B1 But its not
I am a React newbie Please help me understand why a spread operator is used in the following Ive tried to run the same code without using it and I get all