all AI news
toolkit-use npm package have added some functions
July 14, 2023, 12:40 a.m. | toolkituse
DEV Community dev.to
https://kennana.github.io/toolkit-use/guide/date/date.html
日期格式化示例
<script setup lang="ts">
import { ToolkitUseDate } from "toolkit-use/dist/date/index.esm"
const date = new Date()
const str = ToolkitUseDate.formatDate(date, 'yyyy-MM-dd HH:mm:ss')
</script>
formatDate 参数说明
参数 | 说明 | 值类型 |
---|---|---|
dateObj | date实例 | date |
format | 格式化 | string |
判断润年
import { ToolkitUseDate } from "toolkit-use/dist/date/index.esm"
ToolkitUseDate.isLeap(year: number)
获取星期
import { ToolkitUseDate } from "toolkit-use/dist/date/index.esm"
ToolkitUseDate.getWeek( …
esm format import index javascript opensource programming setup string toolkit typescript
More from dev.to / DEV Community
Jobs in AI, ML, Big Data
Senior Machine Learning Engineer
@ GPTZero | Toronto, Canada
ML/AI Engineer / NLP Expert - Custom LLM Development (x/f/m)
@ HelloBetter | Remote
Doctoral Researcher (m/f/div) in Automated Processing of Bioimages
@ Leibniz Institute for Natural Product Research and Infection Biology (Leibniz-HKI) | Jena
Seeking Developers and Engineers for AI T-Shirt Generator Project
@ Chevon Hicks | Remote
Senior Applied Data Scientist
@ dunnhumby | London
Principal Data Architect - Azure & Big Data
@ MGM Resorts International | Home Office - US, NV