Closed gazhay closed 1 year ago
defaultZoneName
was removed with Luxon 2.x. Simply use defaultZone
instead.
Ok, thanks.
Probably needs a documentation update too.
[https://moment.github.io/luxon/#/zones] is where I copied and pasted the above from.
Same result though :-
console.log("Luxon again!", luxon.DateTime.local().zoneName);
luxon.Settings.zoneName = "utc";
console.log("Luxon set to utc", luxon.DateTime.local().zoneName);
Luxon again! Europe/Isle_of_Man
Luxon set to utc Europe/Isle_of_Man
The property is called defaultZone
. You're right though, that part of the documentation is outdated, I'll make sure to update it.
Doh! of course it is, curse my eyesight, Thanks
See #1394 for the docs fix
Describe the bug I'm sure its a "me" bug, but I cannot get defaultZoneName to work at all.
To Reproduce
<script src="/js/luxon.min.js" charset="utf-8"></script>
Actual vs Expected
I expect that the "Luxon now set to" would return "UTC" or similar
Instead :
Linux, Chrome Stable, Version 114.0.5735.106 (Official Build) (64-bit) Luxon [https://moment.github.io/luxon/global/luxon.min.js] TZ : Europe/Isle_of_Man