Suppose to have deployed a lightning web component with a wrong file in its folder structure.
lwc/ └── lwcExample/ ├── WRONG_FILE.html ├── lwcExample.html ├── lwcExample.js └── lwcExample.js-meta.xml
How can you delete from org the wrong file without deleting the component?
Note that the wrong file doesn't have any dependency while the other files might have it. Thus, it is preferable to avoid deleting the whole component and creating it without the wrong file.
I tried to delete it through sfdx with the following command but it tries to delete the whole component.
sfdx force:source:delete --sourcepath "force-app/main/default/lwc/lwcExample/WRONG_FILE.html"