You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Type '"vertical"' is not assignable to type 'Orientation | undefined'.ts(2322)
While I was able to resolve this by importing the RadioGroupOrientation enum from the package, it struck me as odd that the string vertical or horizontal didn't satisfy the orientation prop. Particularly considering the definition of the enum itself 👇
Describe the bug
When using the
VSCodeRadioGroupcomponent, I noticed that the following code resulted in a Typescript errorWhile I was able to resolve this by importing the
RadioGroupOrientationenum from the package, it struck me as odd that the stringverticalorhorizontaldidn't satisfy theorientationprop. Particularly considering the definition of the enum itself 👇As a React developer, I would expect both values –
"vertical"andRadioGroupOrientation.vertical– to function correctly here.Screenshots
https://codesandbox.io/s/purple-shape-j1ih4?file=/src/App.tsx:247-258
Desktop (please complete the following information):