import Document, { Head, Main, NextScript } from 'next/document' import { StyleSheetServer } from 'aphrodite' export default class MyDocument extends Document { static async getInitialProps ({ renderPage }) { const { html, css } = StyleSheetServer.renderStatic(() => renderPage()) return { ...html, css } } render () { return ( My page