Answers for "how to check wether a paticular function in a file in javascript"

1

javascript file exists check

// checking existence of file synchronously
function doesFileExist(urlToFile) {
    var xhr = new XMLHttpRequest();
    xhr.open('HEAD', urlToFile, false);
    xhr.send();
     
    return xhr.status !== 404;
}
Posted by: Guest on June-30-2020

Code answers related to "how to check wether a paticular function in a file in javascript"

Code answers related to "Javascript"

Browse Popular Code Answers by Language