Get user timezone with Javascript

In 2017 it’s relatively easy to get the user timezone with countless of packages available. Nonetheless, there are easier, shorter, faster way to get the user timezone using just vanilla JavaScript, which takes it from the user’s browser if set properly.


var split = new Date().toString().split(" ");
var timeZoneFormatted = split[split.length - 2] + " " + split[split.length - 1]; 

console.log(timeZoneFormatted)
//outputs "GMT+1100 (AEDT)"

Manchester is red! So is my bank account.