Skip to content
This repository has been archived by the owner on Jan 7, 2022. It is now read-only.

Luxon Invalid unit zone #267

Open
amrshakya opened this issue Sep 14, 2021 · 10 comments
Open

Luxon Invalid unit zone #267

amrshakya opened this issue Sep 14, 2021 · 10 comments

Comments

@amrshakya
Copy link

Versions

  • vue: 2.6.14
  • vue-datetime: 1.0.0-beta.14
  • luxon: 2.0.2

Description:

Getting Invalid Unit zone error when use luxon version 2.0.2 but when downgrade luxon version to 1.15.0 the issue seems to be resolved.

Steps To Reproduce:

  • Install latest version luxon & vue-datetime.

Including a reproduction would be great. You can fork this fiddle: https://jsfiddle.net/7mvpgsc4/

@antoineguillaume
Copy link

+1 doesn't work with version 2.0.2 of luxon

@ftbastler
Copy link

+1

3 similar comments
@FarhanKhalid
Copy link

+1

@Nabilezz
Copy link

Nabilezz commented Oct 2, 2021

+1

@alexakuna
Copy link

+1

@eLoyyyyy
Copy link

eLoyyyyy commented Oct 7, 2021

currently I have a workaround until author resolves the dependency to the library itself.

yarn add luxon@1 // so the library resolves the correct version.
yarn add luxon-next@npm:luxon // installed luxon v2.x.x aliased as luxon-next

My version are:

@aguyfromdenmark
Copy link

+1

I ended up just downgrading luxon to lates v1 version npm i [email protected]

@syunchanp
Copy link

syunchanp commented Nov 6, 2021

This issue was effected luxon's change fromObject and normalizeObject method(datetime.js)

You want to revise, remove [zone: "UTC"]
If I had time, I will do pull request of this issure.
Or Someone please pull request this issue.

== DatetimeCalendar.vue:60

  data () {
    return {
      newDate: DateTime.fromObject({ year: this.year, month: this.month, zone: 'UTC' }),

remove zone: "UTC"

  data () {
    return {
      newDate: DateTime.fromObject({ year: this.year, month: this.month }),

westnet-paul added a commit to westnet-paul/vue-datetime that referenced this issue Nov 8, 2021
@RUSHt
Copy link

RUSHt commented Nov 20, 2021

Alternatively you call roll back luxon npm install [email protected]

@SirTadpole
Copy link

+1

The workaround with [email protected] works great.

The correction is pending merge https://github.com/westnet-paul/vue-datetime/commit/ac84c239afe533e31d65e890501a40b4dcf7a1b5

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests