fix: remove jstz, get timezone with Intl

This commit is contained in:
vidvidvid
2021-11-19 08:18:06 +01:00
committed by Alec LaLonde
parent 4a5f7f82a0
commit 4f7d0ef770
3 changed files with 1 additions and 8 deletions

View File

@@ -1,10 +1,9 @@
import jstz from 'jstz';
import React from 'react';
const calId = 'nih59ktgafmm64ed4qk6ue8vv4@group.calendar.google.com';
export const Calendar: React.FC = () => {
const timezone = jstz.determine().name();
const timezone = Intl.DateTimeFormat().resolvedOptions().timeZone;
return (
<iframe

View File

@@ -30,7 +30,6 @@
"fake-tag": "3.0.0",
"graphql": "15.5.0",
"isomorphic-unfetch": "3.1.0",
"jstz": "^2.1.1",
"moment": "2.29.1",
"next": "10.2.3",
"next-images": "1.7.0",

View File

@@ -19780,11 +19780,6 @@ jss@10.6.0, jss@^10.5.1:
is-in-browser "^1.1.3"
tiny-warning "^1.0.2"
jstz@^2.1.1:
version "2.1.1"
resolved "https://registry.yarnpkg.com/jstz/-/jstz-2.1.1.tgz#fff3373a518fa7cce69299930466f5a2b980389d"
integrity sha512-8hfl5RD6P7rEeIbzStBz3h4f+BQHfq/ABtoU6gXKQv5OcZhnmrIpG7e1pYaZ8hS9e0mp+bxUj08fnDUbKctYyA==
"jsx-ast-utils@^2.4.1 || ^3.0.0", jsx-ast-utils@^3.1.0:
version "3.2.0"
resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-3.2.0.tgz#41108d2cec408c3453c1bbe8a4aae9e1e2bd8f82"