Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Add format options for iso week and weekyear #1309

Merged
merged 2 commits into from
Jan 9, 2021
Merged

fix: Add format options for iso week and weekyear #1309

merged 2 commits into from
Jan 9, 2021

Conversation

ChiefORZ
Copy link
Contributor

@ChiefORZ ChiefORZ commented Jan 4, 2021

Like moment.js - day.js should allow the format function to be compatible with iso weeks. and since isoweeks are a plugin already, we can just call it.

Input Example Description
gggg 2014 Locale week year
w ww 1..53 Locale week of year
GGGG 2014 ISO week year
W WW 1..53 ISO week of year

@codecov
Copy link

codecov bot commented Jan 4, 2021

Codecov Report

Merging #1309 (c8c0139) into dev (db2b6a5) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##               dev     #1309   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          175       175           
  Lines         1697      1699    +2     
  Branches       387       388    +1     
=========================================
+ Hits          1697      1699    +2     
Impacted Files Coverage Δ
src/plugin/advancedFormat/index.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update db2b6a5...c8c0139. Read the comment docs.

@iamkun
Copy link
Owner

iamkun commented Jan 5, 2021

This LGTM.

Would you like to update the doc here https://github.com/dayjs/dayjs-website?

The doc in the readme is no longer maintained anymore.

@iamkun iamkun merged commit 2c54c64 into iamkun:dev Jan 9, 2021
iamkun pushed a commit that referenced this pull request Jan 9, 2021
## [1.10.3](v1.10.2...v1.10.3) (2021-01-09)

### Bug Fixes

* fix customParseFormat plugin strict mode parse meridiem bug ([#1321](#1321)) ([e49eeef](e49eeef))
* fix weekYear plugin missing locale bug ([#1319](#1319)) ([344bdc0](344bdc0)), closes [#1304](#1304)
* update advancedFormat plugin to add format options for iso week and weekyear ([#1309](#1309)) ([2c54c64](2c54c64))
* update devHelper to add dev warning setting locale before loading ([c5cc893](c5cc893))
* update German [de] locale yearStart ([1858df8](1858df8)), closes [#1264](#1264)
@iamkun
Copy link
Owner

iamkun commented Jan 9, 2021

🎉 This PR is included in version 1.10.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

@iamkun iamkun added the released label Jan 9, 2021
andrewhood125ruhuc added a commit to andrewhood125ruhuc/SidRH2 that referenced this pull request May 10, 2022
## [1.10.3](iamkun/dayjs@v1.10.2...v1.10.3) (2021-01-09)

### Bug Fixes

* fix customParseFormat plugin strict mode parse meridiem bug ([#1321](iamkun/dayjs#1321)) ([e49eeef](iamkun/dayjs@e49eeef))
* fix weekYear plugin missing locale bug ([#1319](iamkun/dayjs#1319)) ([344bdc0](iamkun/dayjs@344bdc0)), closes [#1304](iamkun/dayjs#1304)
* update advancedFormat plugin to add format options for iso week and weekyear ([#1309](iamkun/dayjs#1309)) ([2c54c64](iamkun/dayjs@2c54c64))
* update devHelper to add dev warning setting locale before loading ([c5cc893](iamkun/dayjs@c5cc893))
* update German [de] locale yearStart ([1858df8](iamkun/dayjs@1858df8)), closes [#1264](iamkun/dayjs#1264)
andrewhood125ruhuc added a commit to andrewhood125ruhuc/SidRH2 that referenced this pull request May 10, 2022
## [1.10.3](iamkun/dayjs@v1.10.2...v1.10.3) (2021-01-09)

### Bug Fixes

* fix customParseFormat plugin strict mode parse meridiem bug ([#1321](iamkun/dayjs#1321)) ([e49eeef](iamkun/dayjs@e49eeef))
* fix weekYear plugin missing locale bug ([#1319](iamkun/dayjs#1319)) ([344bdc0](iamkun/dayjs@344bdc0)), closes [#1304](iamkun/dayjs#1304)
* update advancedFormat plugin to add format options for iso week and weekyear ([#1309](iamkun/dayjs#1309)) ([2c54c64](iamkun/dayjs@2c54c64))
* update devHelper to add dev warning setting locale before loading ([c5cc893](iamkun/dayjs@c5cc893))
* update German [de] locale yearStart ([1858df8](iamkun/dayjs@1858df8)), closes [#1264](iamkun/dayjs#1264)
splashwizard pushed a commit to splashwizard/tracking-time that referenced this pull request Oct 21, 2024
## [1.10.3](iamkun/dayjs@v1.10.2...v1.10.3) (2021-01-09)

### Bug Fixes

* fix customParseFormat plugin strict mode parse meridiem bug ([#1321](iamkun/dayjs#1321)) ([e49eeef](iamkun/dayjs@e49eeef))
* fix weekYear plugin missing locale bug ([#1319](iamkun/dayjs#1319)) ([344bdc0](iamkun/dayjs@344bdc0)), closes [#1304](iamkun/dayjs#1304)
* update advancedFormat plugin to add format options for iso week and weekyear ([#1309](iamkun/dayjs#1309)) ([2c54c64](iamkun/dayjs@2c54c64))
* update devHelper to add dev warning setting locale before loading ([c5cc893](iamkun/dayjs@c5cc893))
* update German [de] locale yearStart ([1858df8](iamkun/dayjs@1858df8)), closes [#1264](iamkun/dayjs#1264)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants