Console.log not working when testing regex
问题 Can someone explain why my console log is not working? Every time I select the file for verification to see if anything shows in the console nothing happens document.addEventListener("DOMContentLoaded", function() { document.getElementById('file').onchange = function() { var extPermitidas = ['txt']; var extArquivo = this.value.split('.').pop(); if (typeof extPermitidas.find(function(ext) { return extArquivo == ext; }) == 'undefined') { alert('The file cannot be used because its extension is