Closed halohalospecial closed 8 years ago
Thank you! I will try to test this out tomorrow.
I think accommodating for the linter is the right move
Could you also remove commented code that's not used and amend that?
Sorry, I'm using my phone right now. I can change it tomorrow.
Hi @benjick, I already removed the commented code. Thanks!
Thanks again @halohalospecial, I've published this now!
Thanks @benjick @floriangrundig !
Hi! Currently, those using
linter-elm-make
are having issues when they haveelm-format
installed. It's becauseelm-format
is saving the file again, resulting to 2 lints. There's anelm-make
bug that's causing warnings to disappear inlinter-elm-make
when the file is saved another time without changes.This PR tries to remedy the issue by formatting the text in
onWillSave
instead ofonDidSave
. It also needed the operation to be synchronous, thereforespawnSync
was used. Finally,setTextViaDiff
was used to remove the flicker caused by syntax highlighting computation.References: https://github.com/elm-lang/elm-make/issues/114 https://github.com/mybuddymichael/linter-elm-make/issues/81
Sorry if the changes are quite significant. I'll perfectly understand if you will not accept the PR since it will change the current behavior of
elm-format
.Thanks!