diff --git a/pages/_document.js b/pages/_document.js
index a3615cc17..c645f3c12 100644
--- a/pages/_document.js
+++ b/pages/_document.js
@@ -1,27 +1,26 @@
-import React from 'react'
-import Document, { Html, Head, Main, NextScript } from 'next/document'
+// updated based on documentation: https://github.com/vercel/next.js/blob/canary/examples/with-styled-components/pages/_document.tsx
+import Document, { DocumentContext, Html, Head, Main, NextScript } from 'next/document'
import { ServerStyleSheet } from 'styled-components'
export default class MyDocument extends Document {
static async getInitialProps (ctx) {
const sheet = new ServerStyleSheet()
- const page = ctx.renderPage(App => props => sheet.collectStyles(