const getMonthRange = (yearMonth) => {
  // yearMonth 格式：'2026-03'
  const [year, month] = yearMonth.split('-');
  
  // 当月第一天
  const firstDay = `${year}-${month}-01`;
  
  // 当月最后一天：先获取下个月的第0天，即当月的最后一天
  const lastDay = new Date(Number(year), Number(month), 0);
  const lastDayStr = `${year}-${month}-${lastDay.getDate()}`;
  
  return [firstDay, lastDayStr];
}

export default getMonthRange

