iamkun / iamkun/dayjs

Format constant/enum

Open
#1,867 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
48.7k
Forks
2.5k
PR merge metrics
No merged PRs in 30d

Description

It seems that there are no `enum` to apply formats.
We must use strings everytime (e.g. `.format("L")`.
IIt would be nice to have already made values, for instance, (like Luxon allows) `.format(DateTime.DATE_SHORT)` -> "01/22/22".

Contributor guide

Open the contributing guide

Research direction

Start by reviewing Day.js's existing format API and the Luxon example in the issue to determine which named constants are in scope. Define the intended constant names and output values, then verify that formatting with each constant produces the documented result.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
backend-api-design
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.