Open
Description
TypeScript Version: 4.2.0-dev.20201109
Search Terms:
String literal rename
Code
type Actions = { type: 'one', payload: number } | { type: 'two', payload: boolean }
const q: Actions = { type: 'one', payload: 1 }
Expected behavior:
Renaming of values of 'type' fields should also rename the value in actual variable. For example if I rename 'one'
in the type Actions
TS should also rename the value of type
field in q
variable, and vice versa.
Actual behavior:
Looks like renaming doesn't start at all