Accepts transliterated names ('Cheshvan', 'Sh'vat'), Hebrew-script
names with or without nikud ('חשון', 'תִּשְׁרֵי'), an optional bet
prefix ('בתמוז'), and passes numbers through unchanged. Matching is
case-insensitive and only needs enough of the name to be unambiguous.
'Adar' resolves to Adar I; 'Adar II' (and 'אדר ב׳') to Adar II.
Parameters
monthName: string|number
monthName
Returns number
Hebrew month number (1=NISAN, 7=TISHREI)
Throws
if monthName is neither a string nor a number
Throws
if the name is not recognized, or a numeric month
is outside 1-14
Converts Hebrew month string name to numeric.
Accepts transliterated names (
'Cheshvan','Sh'vat'), Hebrew-script names with or without nikud ('חשון','תִּשְׁרֵי'), an optional bet prefix ('בתמוז'), and passes numbers through unchanged. Matching is case-insensitive and only needs enough of the name to be unambiguous.'Adar'resolves to Adar I;'Adar II'(and'אדר ב׳') to Adar II.