Skip to content

Commit 2696db0

Browse files
committed
Remove typeof hack to test [email protected]
1 parent dea0614 commit 2696db0

File tree

9 files changed

+10
-29
lines changed

9 files changed

+10
-29
lines changed

pages/_app.page/page-layout.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
import * as React from "react";
2-
import _styled, { createGlobalStyle, css } from "styled-components";
2+
import styled, { createGlobalStyle, css } from "styled-components";
33
import { normalize } from "styled-normalize";
44

55
import { ExternalLink } from "../shared/external-link.jsx";
66

7-
const styled = _styled as unknown as typeof _styled.default;
8-
97
const base = css`
108
body {
119
color: #24292e;

pages/_document.page.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import _Document, {
1+
import Document, {
22
DocumentContext,
33
Head,
44
Html,
@@ -8,8 +8,6 @@ import _Document, {
88
import * as React from "react";
99
import { ServerStyleSheet } from "styled-components";
1010

11-
const Document = _Document as unknown as typeof _Document.default;
12-
1311
export default class MyDocument extends Document {
1412
static async getInitialProps(ctx: DocumentContext) {
1513
const sheet = new ServerStyleSheet();

pages/index.page.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
import * as React from "react";
2-
import _styled from "styled-components";
2+
import styled from "styled-components";
33

44
import { AvailableDestinations } from "./index.page/available-destinations.jsx";
55
import { Example } from "./index.page/example.jsx";
66
import { InputForm } from "./index.page/input-form.jsx";
77
import { ExternalLink } from "./shared/external-link.jsx";
88
import { PageMetadata } from "./shared/page-metadata.jsx";
99

10-
const styled = _styled as unknown as typeof _styled.default;
11-
1210
const H2 = styled.h2`
1311
margin-top: 3em;
1412
font-size: 1em;

pages/index.page/available-destinations.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
import * as React from "react";
2-
import _styled from "styled-components";
2+
import styled from "styled-components";
33

44
import { ExternalLink } from "../shared/external-link.jsx";
55
import { ClickableCode } from "./clickable-code.jsx";
66

7-
const styled = _styled as unknown as typeof _styled.default;
8-
97
const Ul = styled.ul`
108
padding-left: 0;
119
overflow: hidden;

pages/index.page/clickable-code.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
import _styled from "styled-components";
2-
3-
const styled = _styled as unknown as typeof _styled.default;
1+
import styled from "styled-components";
42

53
export const ClickableCode = styled.code`
64
border-bottom: 1px dotted transparent;

pages/index.page/example.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
import * as React from "react";
2-
import _styled from "styled-components";
2+
import styled from "styled-components";
33

44
import { ExternalLink } from "../shared/external-link.jsx";
55
import { ClickableCode } from "./clickable-code.jsx";
66

7-
const styled = _styled as unknown as typeof _styled.default;
8-
97
const Remark = styled.span`
108
white-space: nowrap;
119
`;

pages/index.page/input-form.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
import * as React from "react";
2-
import _styled from "styled-components";
3-
4-
const styled = _styled as unknown as typeof _styled.default;
2+
import styled from "styled-components";
53

64
const verticalFormPadding = 20;
75

pages/shared/error-page-body.tsx

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
1-
import _Link from "next/link.js";
1+
import Link from "next/link.js";
22
import * as React from "react";
3-
import _styled from "styled-components";
4-
5-
const Link = _Link as unknown as typeof _Link.default;
6-
const styled = _styled as unknown as typeof _styled.default;
3+
import styled from "styled-components";
74

85
const Container = styled.div`
96
text-align: center;

pages/shared/page-metadata.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
1-
import _Head from "next/head.js";
1+
import Head from "next/head.js";
22
import * as React from "react";
33

4-
const Head = _Head as unknown as typeof _Head.default;
5-
64
const getBaseUrl = () => {
75
const hostname =
86
process.env.VERCEL_URL ?? process.env.HOSTNAME ?? "njt.vercel.app";

0 commit comments

Comments
 (0)