facebook / flow

Adds static typing to JavaScript to improve developer productivity and code quality.
https://flow.org/
MIT License
22.07k stars 1.85k forks source link

Support specifying generics to tagged template string functions #7527

Open mgtitimoli opened 5 years ago

mgtitimoli commented 5 years ago

Flow version: All

Expected behavior

Tagged template strings functions should support specifying generics at call time

Actual behavior

Tagged template strings functions does not support specifying generics at call time

FezVrasta commented 4 years ago

Is anyone aware of any workaround for this?

FezVrasta commented 4 years ago

To give some context, this affects Emotion styled components Flow types.

type Props = { color: string };
const Foo = styled.div<Props>`
  color: ${props => props.color};
`;
FezVrasta commented 1 month ago

@SamChou19815 any explanation?

SamChou19815 commented 1 month ago

Sorry this one is closed by accident, but there is still no plan to support this