[Edge]。→
Date の、地方時に基づく「月」を表す数値(0~11)で返します。
| Date | Date。 |
|---|
数値。0=1 月、1=2 月、…、11=12 月。
以下の 2 行目の文は、Date オブジェクト Xmas95 の値に基づき、変数 month に 11 という値を代入します。
var Xmas95 = new Date('December 25, 1995 23:15:30');
var month = Xmas95.getMonth(); //=11
var options = { month: 'long'};
D=new Intl.DateTimeFormat('en-US', options).format(Xmas95); //=December
D=new Intl.DateTimeFormat('de-DE', options).format(Xmas95); //=Dezember