Files
SnowLuma/.pnpm-store/v11/files/74/e0eaf12f268bb5aaf3b3e514a6e565088a2cc93432fbfaf4109f7e01be1ddb1c43a86e31d188513d63556b7c0be1d3538f9001df16770c24e418baa0dd7042
T
TanTan 2a69b23b47
Dev Build / cleanup (push) Canceled after 0s
Dev Build / typecheck (push) Canceled after 0s
Dev Build / build (linux-arm64, ubuntu-24.04-arm, linux-arm64) (push) Canceled after 0s
Dev Build / build (linux-x64, ubuntu-latest, linux-x64) (push) Canceled after 0s
Dev Build / build (win-x64, windows-latest, win32-x64) (push) Canceled after 0s
Dev Build / dispatch-dev-docker (push) Canceled after 0s
docs: 仓库链接指向本镜像仓库
2026-11-13 09:27:07 +08:00

16 lines
594 B
Plaintext

/**
* Subtracts a specified number of hours from a date.
* 从日期中减去指定数量的小时。
*
* @param date - The date to subtract hours from. (要从日期中减去的小时数。)
* @param hours - The number of hours to subtract. (要减去的小时数。)
* @returns A new date with the subtracted hours. (减去小时后的新日期。)
* @example
* ```ts
* //Subtracting 3 hours from a date (从日期中减去3)
* subHours(new Date(2014, 6, 2, 11, 55), 3);
* //=> Thu Jul 02 2015 08:55:00
* ```
*/
export default function subHours(date: Date, hours: number): Date;