MCPcopy
hub / github.com/cloudflare/mcp-server-cloudflare / getMonthIndex

Function getMonthIndex

apps/demo-day/frontend/script.js:516–543  ·  view source on GitHub ↗
(month)

Source from the content-addressed store, hash-verified

514
515 // Helper function to get month index (0-11) from month name
516 function getMonthIndex(month) {
517 const months = {
518 JANUARY: 0,
519 JAN: 0,
520 FEBRUARY: 1,
521 FEB: 1,
522 MARCH: 2,
523 MAR: 2,
524 APRIL: 3,
525 APR: 3,
526 MAY: 4,
527 JUNE: 5,
528 JUN: 5,
529 JULY: 6,
530 JUL: 6,
531 AUGUST: 7,
532 AUG: 7,
533 SEPTEMBER: 8,
534 SEP: 8,
535 OCTOBER: 9,
536 OCT: 9,
537 NOVEMBER: 10,
538 NOV: 10,
539 DECEMBER: 11,
540 DEC: 11,
541 }
542 return months[month.toUpperCase()]
543 }
544})
545
546// Helper functions

Callers 1

parseDateTimeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected