Golang - Why does vscode delete golang source on save - Stack Overflow

PHOTO EMBED

Sat Nov 21 2020 02:28:05 GMT+0000 (Coordinated Universal Time)

Saved by @robertjbass #go

"[go]": {

        "editor.formatOnSave": false,
        "editor.codeActionsOnSave": {
            "source.organizeImports": false
        },
    },
    "go.formatTool": "gofmt",
content_copyCOPY

If go deletes your text on save, this is the config to fix that in vscode settings

https://stackoverflow.com/questions/48124565/why-does-vscode-delete-golang-source-on-save