You can't do what you're asking using built-in methods as ECMAScript implementations aren't required to store historical data for all (or even any) time zones. They are only required to have access to the current time zone offset of the host.
Also, the ECMA-402 Internationalisation API isn't sufficient either. While it allows the timezone to be specified, not all implementations support ECMA-402 and of those that do, not all support time zones values other than "UTC" (which is the only one ECMA-402 requires support for, others are optional). And it's very difficult to impossible to exactly specify the format using only ECMA-402.
I think you're much better off to use an existing library like moment.js with Moment-timezone.js. The download isn't that big relative to the general size of web pages (which seem to be 1MB at least lately). If you try to write something yourself you'll just end up with something very moment-like anyway.
To reduce the size of the download, you can get just the time zone data for 2012 to 2022.
If you want to use your simplified call, then a small magicDateFormatter can leverage the moment.js stuff:
/* Return date string for a date in the required timezone and format
** @param {string} timezone: IANA time zone designator, e.g. Asia/Sakhalin
** @param {Date} [date] : date to use, default is current date
** @param {string} [format]: output format using Moment.js tokens,
** default is 'YYYY-MM-DDTHH:mm:ssZZ'
** @returns {string} : formatted string
**
** magicDateFormatter(timezone[, date[, format]])
*/
function magicDateFormatter(timezone, date, format) {
// Validate that the time zone is supported
if (!moment.tz.zone(timezone)) {
return 'Unknown time zone: "' + timezone + '"';
}
// Use current date if not supplied
date = date || new Date();
// Use default format if not supplied
format = format || 'YYYY-MM-DDTHH:mm:ssZZ'
return moment(date).tz(timezone).format(format)
}
console.log(magicDateFormatter('Europe/Paris'));
console.log(magicDateFormatter('Asia/Sakhalin', new Date(2016,1,29), 'Do MMMM, YYYY'));
console.log(magicDateFormatter('foo/bar'));
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.18.1/moment.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment-timezone/0.5.13/moment-timezone-with-data.min.js"></script>
Of course you could also specify the format in the call if you want.