estou usando o editor de texto brackets para fazer os exercícios, mas o que me incomoda é que alguns trechos de códigos como events e alerts estão com avisos de erro, porém continuam funcionando. Alguém poderia me explicar por que isso acontece ?
JSLint (3)
7
Missing space between 'for' and '('. for(var i = 0; i < pacientes.length; i++)
7
Move 'var' declarations to the top of the function. for(var i = 0; i < pacientes.length; i++)
7
Stopping. (6% scanned). for(var i = 0; i < pacientes.length; i++)
ESLint (10)
1
ERROR: 'document' is not defined. [no-undef] var titulo = document.querySelector(".titulo"); //Armazenamento do conteudo do class ".titulo" numa variável titulo.
5
ERROR: 'document' is not defined. [no-undef] var pacientes = document.querySelectorAll(".paciente"); //Armazena na variável "paciente" todo o conteúdo da tag dentro do parentese; esse conteudo pode ser acessado atraves d
22
ERROR: Unexpected console statement. [no-console] console.log("Peso inválido");
22
ERROR: 'console' is not defined. [no-undef] console.log("Peso inválido");
31
ERROR: Unexpected console statement. [no-console] console.log("Altura inválida");
31
ERROR: 'console' is not defined. [no-undef] console.log("Altura inválida");
40
ERROR: Mixed spaces and tabs. [no-mixed-spaces-and-tabs] var imc = peso/ (altura * altura); //Executando uma operação matemática com ele.
48
ERROR: 'alert' is not defined. [no-undef] alert("Olá eu fui clicado!");
51
ERROR: 'document' is not defined. [no-undef] var EventoDoBotao = document.querySelector(".bto-principal");
54
ERROR: 'alert' is not defined. [no-undef] alert("Olá eu fui clicado!");