sdk icon indicating copy to clipboard operation
sdk copied to clipboard

Renaming a widget should update file name when file name is same as widget

Open keertip opened this issue 2 years ago • 2 comments

If the file name is the same as widget, renaming a widget should update the file name and imports to point to the new resource. It should convert between camelcase and underscore.

keertip avatar Aug 01 '22 18:08 keertip

I suspect that we want this behavior to apply to any top-level declaration whose name matches (modulo identifier style) the name of the file in which it's declared.

bwilkerson avatar Aug 01 '22 21:08 bwilkerson

Well IMO, I don't think it's nice to update the file name when a widget with similar name is updated. It's going to break in other files where the path of file is. Except in recent cases, where you can refactor the file path for all destinations

Captured-Heart avatar Aug 05 '22 22:08 Captured-Heart