diff --git a/examples/with-react-jss/package.json b/examples/with-react-jss/package.json index 325bec25..d2835188 100644 --- a/examples/with-react-jss/package.json +++ b/examples/with-react-jss/package.json @@ -7,10 +7,10 @@ "start": "next start" }, "dependencies": { - "next": "latest", + "next": "canary", "react": "^16.7.0", "react-dom": "^16.7.0", - "react-jss": "8.6.1" + "react-jss": "10.0.0-alpha.9" }, "license": "ISC" } diff --git a/examples/with-react-jss/pages/_document.js b/examples/with-react-jss/pages/_document.js index a18a4e9a..3d7268b2 100644 --- a/examples/with-react-jss/pages/_document.js +++ b/examples/with-react-jss/pages/_document.js @@ -1,15 +1,16 @@ import React from 'react' import Document, { Head, Main, NextScript } from 'next/document' -import { SheetsRegistry, JssProvider } from 'react-jss' +import { SheetsRegistry, JssProvider, createGenerateId } from 'react-jss' export default class JssDocument extends Document { static async getInitialProps (ctx) { const registry = new SheetsRegistry() + const generateId = createGenerateId() const originalRenderPage = ctx.renderPage ctx.renderPage = () => originalRenderPage({ enhanceApp: App => props => ( - + ) diff --git a/examples/with-react-jss/pages/index.js b/examples/with-react-jss/pages/index.js index b89863e3..3d90e62f 100644 --- a/examples/with-react-jss/pages/index.js +++ b/examples/with-react-jss/pages/index.js @@ -1,5 +1,5 @@ import React from 'react' -import injectSheet from 'react-jss' +import withStyles from 'react-jss' const styles = { container: { @@ -23,4 +23,4 @@ function Index (props) { ) } -export default injectSheet(styles)(Index) +export default withStyles(styles)(Index)