headwind icon indicating copy to clipboard operation
headwind copied to clipboard

Run plugin only on manual saving

Open karladler opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe. As described here, saving is doing funny stuff with the current cursor position. Since the plugin runs also on autosave it sometimes get's pretty unhandy editing the classes.

https://github.com/heybourn/headwind/issues/72

Describe the solution you'd like The VS-Code API offers the possibility to determine what was the trigger for saving. So I would suggest to run only on manually saving (CMD+s) or make it an option.

"headwind.runOnAutoSave": true | false

Describe alternatives you've considered Delaying auto save for a few seconds mitigates the problem, but raises others.

Additional context I think it would be best practice not to run on autosave. It would be also the same behavior as "eslint auto fixing", which also runs only on manual save.

karladler avatar Feb 15 '21 10:02 karladler