What is the difference between throw and throw new Error, I'm a bit confused it seems an Error object is created with just the throw keyword, so why is the new Error used with throw? example
try{
throw "something went wrong";//this works
}
catch(e){
console.log(e);
}
try{
throw new Error("something went wrong");//this also works but with
// longer syntax
}
catch(e){
console.log(e);
}