Skip to main content

@xtool/dayjs@0.1.3

latest
Works with
JSR Score
52%
Published
3 weeks ago

dayjs

https://github.com/iamkun/dayjs.

Examples

first new a ts file named test.ts.

import { dayjs } from "@xtool/dayjs";

let str = dayjs().format("YYYY-MM-DD HH:mm:ss"); // 格式化字符串
console.log(str);

let week = dayjs().day(); // 返回星期几
console.log(week);

then run the below command:

# install the module
$ deno add @xtool/dayjs

# run the test.ts
$ deno run test.ts

Add Package

deno add @xtool/dayjs

Import symbol

import * as mod from "@xtool/dayjs";

Add Package

npx jsr add @xtool/dayjs

Import symbol

import * as mod from "@xtool/dayjs";

Add Package

yarn dlx jsr add @xtool/dayjs

Import symbol

import * as mod from "@xtool/dayjs";

Add Package

pnpm dlx jsr add @xtool/dayjs

Import symbol

import * as mod from "@xtool/dayjs";

Add Package

bunx jsr add @xtool/dayjs

Import symbol

import * as mod from "@xtool/dayjs";