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

Add ObjectSupport TypeScript definition(s) #1441

Closed
AviBueno opened this issue Apr 5, 2021 · 5 comments · Fixed by #1990
Closed

Add ObjectSupport TypeScript definition(s) #1441

AviBueno opened this issue Apr 5, 2021 · 5 comments · Fixed by #1990
Labels

Comments

@AviBueno
Copy link

AviBueno commented Apr 5, 2021

Describe the bug
Attempting to initialize a dayjs object based on ObjectSupport syntax under a TypeScript project yields the following error: Type 'number' is not assignable to type '{ (): number; (value: number): Dayjs; }'.

Expected behavior
The dayjs index.d.ts file should be updated such that object-based initialization would be possible.

Information

  • Day.js Version: v1.10.4
  • OS: MacOS
  • Browser: Irrelevant. Node.js project.
  • Time zone: UTC
@kuanyui
Copy link

kuanyui commented Jan 7, 2022

Any news on this issue?

@manix84
Copy link

manix84 commented Jan 14, 2022

+1: Still occurring in v1.10.7

@adam-marshall
Copy link

affecting me in 1.11.3

@autopp
Copy link
Contributor

autopp commented Jul 18, 2022

I created PR #1990 for this issue.

iamkun pushed a commit that referenced this issue Jul 19, 2022
## [1.11.4](v1.11.3...v1.11.4) (2022-07-19)

### Bug Fixes

* correct past property in ku (kurdish) locale ([#1916](#1916)) ([74e82b9](74e82b9))
* fix French [fr] local ordinal ([#1932](#1932)) ([8f09834](8f09834))
* fix objectSupport plugin ConfigTypeMap type ([#1441](#1441)) ([#1990](#1990)) ([fd51fe4](fd51fe4))
* fix type error to add ordianl property in InstanceLocaleDataReturn and GlobalLocaleDataReturn types ([#1931](#1931)) ([526f0ae](526f0ae))
* update locale ar-* meridiem function ([#1954](#1954)) ([3d31611](3d31611))
* zh-tw / zh-hk locale ordinal error ([#1976](#1976)) ([0a1bd08](0a1bd08))
@iamkun
Copy link
Owner

iamkun commented Jul 19, 2022

🎉 This issue has been resolved in version 1.11.4 🎉

The release is available on:

Your semantic-release bot 📦🚀

BePo65 pushed a commit to BePo65/dayjs that referenced this issue Aug 6, 2022
## [1.11.4](iamkun/dayjs@v1.11.3...v1.11.4) (2022-07-19)

### Bug Fixes

* correct past property in ku (kurdish) locale ([iamkun#1916](iamkun#1916)) ([74e82b9](iamkun@74e82b9))
* fix French [fr] local ordinal ([iamkun#1932](iamkun#1932)) ([8f09834](iamkun@8f09834))
* fix objectSupport plugin ConfigTypeMap type ([iamkun#1441](iamkun#1441)) ([iamkun#1990](iamkun#1990)) ([fd51fe4](iamkun@fd51fe4))
* fix type error to add ordianl property in InstanceLocaleDataReturn and GlobalLocaleDataReturn types ([iamkun#1931](iamkun#1931)) ([526f0ae](iamkun@526f0ae))
* update locale ar-* meridiem function ([iamkun#1954](iamkun#1954)) ([3d31611](iamkun@3d31611))
* zh-tw / zh-hk locale ordinal error ([iamkun#1976](iamkun#1976)) ([0a1bd08](iamkun@0a1bd08))
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 a pull request may close this issue.

6 participants