-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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 setDefault
typing to timezone.d.ts
#1057
fix: Add setDefault
typing to timezone.d.ts
#1057
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #1057 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 172 172
Lines 1522 1522
Branches 321 321
=========================================
Hits 1522 1522 Continue to review full report at Codecov.
|
types/plugin/timezone.d.ts
Outdated
@@ -11,6 +11,7 @@ declare module 'dayjs' { | |||
interface DayjsTimezone { | |||
(date: ConfigType, timezone: string): Dayjs | |||
guess(): string | |||
setDefault(timezone?: string): Dayjs |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
setDefault function returns nothing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I got it, I'm replacing Dayjs
to void
, Thanks!
Thanks |
# [1.9.0](v1.8.36...v1.9.0) (2020-09-28) ### Bug Fixes * Add `setDefault` typing to timezone.d.ts ([#1057](#1057)) ([c0f0886](c0f0886)) * fix DST bug in utc plugin ([#1053](#1053)) ([3d73543](3d73543)) * Fix optional type for timezone plugin ([#1081](#1081)) ([a6ebcf2](a6ebcf2)), closes [#1079](#1079) * Fix timezone plugin conversion bug ([#1073](#1073)) ([16816a3](16816a3)) * update duration plugin type file ([#1065](#1065)) ([94af9af](94af9af)) * update timezone plugin to support getting offset name e.g. EST ([#1069](#1069)) ([cbb755e](cbb755e)) * update utc plugin to support keepLocalTime `.utc(true)` ([#1080](#1080)) ([5ce4e0d](5ce4e0d)) ### Features * Correct casing for en-sg locale name ([#1048](#1048)) ([2edaddc](2edaddc))
# [1.9.0](iamkun/dayjs@v1.8.36...v1.9.0) (2020-09-28) ### Bug Fixes * Add `setDefault` typing to timezone.d.ts ([#1057](iamkun/dayjs#1057)) ([c0f0886](iamkun/dayjs@c0f0886)) * fix DST bug in utc plugin ([#1053](iamkun/dayjs#1053)) ([3d73543](iamkun/dayjs@3d73543)) * Fix optional type for timezone plugin ([#1081](iamkun/dayjs#1081)) ([a6ebcf2](iamkun/dayjs@a6ebcf2)), closes [#1079](iamkun/dayjs#1079) * Fix timezone plugin conversion bug ([#1073](iamkun/dayjs#1073)) ([16816a3](iamkun/dayjs@16816a3)) * update duration plugin type file ([#1065](iamkun/dayjs#1065)) ([94af9af](iamkun/dayjs@94af9af)) * update timezone plugin to support getting offset name e.g. EST ([#1069](iamkun/dayjs#1069)) ([cbb755e](iamkun/dayjs@cbb755e)) * update utc plugin to support keepLocalTime `.utc(true)` ([#1080](iamkun/dayjs#1080)) ([5ce4e0d](iamkun/dayjs@5ce4e0d)) ### Features * Correct casing for en-sg locale name ([#1048](iamkun/dayjs#1048)) ([2edaddc](iamkun/dayjs@2edaddc))
# [1.9.0](iamkun/dayjs@v1.8.36...v1.9.0) (2020-09-28) ### Bug Fixes * Add `setDefault` typing to timezone.d.ts ([#1057](iamkun/dayjs#1057)) ([c0f0886](iamkun/dayjs@c0f0886)) * fix DST bug in utc plugin ([#1053](iamkun/dayjs#1053)) ([3d73543](iamkun/dayjs@3d73543)) * Fix optional type for timezone plugin ([#1081](iamkun/dayjs#1081)) ([a6ebcf2](iamkun/dayjs@a6ebcf2)), closes [#1079](iamkun/dayjs#1079) * Fix timezone plugin conversion bug ([#1073](iamkun/dayjs#1073)) ([16816a3](iamkun/dayjs@16816a3)) * update duration plugin type file ([#1065](iamkun/dayjs#1065)) ([94af9af](iamkun/dayjs@94af9af)) * update timezone plugin to support getting offset name e.g. EST ([#1069](iamkun/dayjs#1069)) ([cbb755e](iamkun/dayjs@cbb755e)) * update utc plugin to support keepLocalTime `.utc(true)` ([#1080](iamkun/dayjs#1080)) ([5ce4e0d](iamkun/dayjs@5ce4e0d)) ### Features * Correct casing for en-sg locale name ([#1048](iamkun/dayjs#1048)) ([2edaddc](iamkun/dayjs@2edaddc))
# [1.9.0](iamkun/dayjs@v1.8.36...v1.9.0) (2020-09-28) ### Bug Fixes * Add `setDefault` typing to timezone.d.ts ([#1057](iamkun/dayjs#1057)) ([c0f0886](iamkun/dayjs@c0f0886)) * fix DST bug in utc plugin ([#1053](iamkun/dayjs#1053)) ([3d73543](iamkun/dayjs@3d73543)) * Fix optional type for timezone plugin ([#1081](iamkun/dayjs#1081)) ([a6ebcf2](iamkun/dayjs@a6ebcf2)), closes [#1079](iamkun/dayjs#1079) * Fix timezone plugin conversion bug ([#1073](iamkun/dayjs#1073)) ([16816a3](iamkun/dayjs@16816a3)) * update duration plugin type file ([#1065](iamkun/dayjs#1065)) ([94af9af](iamkun/dayjs@94af9af)) * update timezone plugin to support getting offset name e.g. EST ([#1069](iamkun/dayjs#1069)) ([cbb755e](iamkun/dayjs@cbb755e)) * update utc plugin to support keepLocalTime `.utc(true)` ([#1080](iamkun/dayjs#1080)) ([5ce4e0d](iamkun/dayjs@5ce4e0d)) ### Features * Correct casing for en-sg locale name ([#1048](iamkun/dayjs#1048)) ([2edaddc](iamkun/dayjs@2edaddc))
Timezone plugin set default timezone at v1.8.36, however
timezone.d.ts
does not have type definition ofsetDefault
method.