The phrase "compliant with year-2000" is a bit misleading, and probably should be removed.
Initially, ECMAScript was implemented with a Java-like method called getYear which returned a 2 digit year that was the full year - 1900, so 1995 was returned as 95, 2017 as 117 and 1832 as -68. This method has now been moved to an appendix of ECMA-262 for web browsers only and is maintained for backward compatibility reasons, it should not be used in new code.
Although the getYear method seems a bit weird now, it was easily converted to a full year by adding 1900.
The "Y2K" issue is that 2 digit years became an issue after 1 Jan 2000 as a date like 1/1/00 would be interpreted as 1/1/1900 when 1/1/2000 was intended (and so on for any 2 digit year). This issue persists, since new Date(0,0,1)
creates a date for 1/1/1900, not 1/1/0000.
That is the real year 2000 (Y2K) issue, not getting the year.
To create a date between -99 and +99, you need to set the full year, e.g. for 1 Jan 23 you need to do:
var d = new Date();
d.setFullYear(23,0,1);
In regard to getFullYear (and getUTCFullYear), it returns the full year, which can be any year that is roughly ±285,616 from 1970. It doesn't, of itself, avoid the Y2K issue. But it will return the actual year:
var d = new Date();
d.setFullYear(23, 0, 1);
console.log(d.getYear()); // -1877
console.log(d.getFullYear()); // 23