I have realized a behaviour of VSCode that causing conflict on committing files in an Angular project. When saving a file (*.ts), VSCode removes the ending whitespaces autom