I am migrating my reactjs app in ES6. It used some external javascript which defines global variables in old way and no exports. There is no way i can change and maintain the same.
When a function inside that file is referenced, I get uncaught referenceerror
for the functions defined without keyword var/const.
What is the correct way to use this kind of files in ES6?
e.g.If an old third party js file contains following code. I get an uncaught reference error for ClassicClient during execution in browser.
ClassicClient = function(x, y){
return x+y;
}