承接 maarheeze/calendar-date 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

maarheeze/calendar-date

最新稳定版本:1.1.0

Composer 安装命令:

composer require maarheeze/calendar-date

包简介

a timezone-agnostic calendar date value object

README 文档

README

A timezone-agnostic calendar date value object for PHP. No time component, no timezone concerns.

Requirements

  • PHP 8.2+

Installation

composer require maarheeze/calendar-date

Usage

Creating a date

CalendarDate::today();
CalendarDate::parse('2000-01-01');
CalendarDate::parse('today');
CalendarDate::parse('+3 weeks');
CalendarDate::instance($dateTimeInterface);
CalendarDate::createFromFormat('d-m-Y', '01-01-2000');

Formatting

$date->format('Y-m-d');
$date->__toString(); // defaults to Y-m-d

Arithmetic

$date->addDays(7);
$date->subDays(7);
$date->addMonths(1);
$date->subMonths(1);
$date->addYears(1);
$date->subYears(1);

All arithmetic methods return a new CalendarDate instance.

Comparison

$date->equalTo($other);
$date->isBefore($other);
$date->isAfter($other);
$date->isToday();
$date->isPast();
$date->isFuture();

License

MIT

统计信息

  • 总下载量: 3
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 6
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-03-06

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固