EN
JavaScript - English month names
4
points
This article was created to speed up software developer programming by providing JavaScript arrays with month names.
Quick solution:
const MONTH_FULL_NAMES = [
'January',
'February',
'March',
'April',
'May',
'June',
'July',
'August',
'September',
'October',
'November',
'December'
];
Inline:
const MONTH_FULL_NAMES = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'];
Abbreviations:
const MONTH_SHORT_NAMES = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
Details
In this section, you can see other ways to name months with number of days.
-----------------------------------------------------------------------------
| [ month name ] | |
|------------------------------------| [ number of days ] |
| [ full name ] [ abbreviation ] | |
|------------------------------------|--------------------------------------|
| | |
| January Jan. | 31 days |
| February Feb. | 28 days (29 days in leap years) | https://dirask.com/posts/JavaScript-check-if-specific-year-is-leap-przo3p
| March Mar. | 31 days |
| April Apr. | 30 days |
| May May. | 31 days |
| June Jun. | 30 days |
| July Jul. | 31 days |
| August Aug. | 31 days |
| September Sep. | 30 days |
| October Oct. | 31 days |
| November Nov. | 30 days |
| December Dec. | 31 days |
| | |
-----------------------------------------------------------------------------
Abbreviations (with dots):
const MONTH_SHORT_NAMES = ['Jan.', 'Feb.', 'Mar.', 'Apr.', 'May.', 'Jun.', 'Jul.', 'Aug.', 'Sep.', 'Oct.', 'Nov.', 'Dec.'];