As anotações de tipo só podem ser usadas em arquivos tipycript.
one solution can be to disable the typescript check. so inside the settings.json
add the below code line
"javascript.validate.enable": false
Lokesh003