Unverified Commit 1c8eda30 authored by Jam Balaya's avatar Jam Balaya Committed by GitHub

examples: update `with-styletron` README.md (#73411)

## Description

Follow up #73252.
This example no more uses `<Document />` and `<head>`.
So, I update it.

CC: @samcx 

### Adding or Updating Examples

- [x] The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- [x] Make sure the linting passes by running `pnpm build && pnpm lint`.
See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.mdCo-authored-by: 's avatarSam Ko <sam@vercel.com>
parent 95acd8b4
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
This example features how yo use a different styling solution than [styled-jsx](https://github.com/vercel/styled-jsx) that also supports universal styles. That means we can serve the required styles for the first render within the HTML and then load the rest in the client. In this case we are using [styletron](https://github.com/rtsao/styletron). This example features how yo use a different styling solution than [styled-jsx](https://github.com/vercel/styled-jsx) that also supports universal styles. That means we can serve the required styles for the first render within the HTML and then load the rest in the client. In this case we are using [styletron](https://github.com/rtsao/styletron).
For this purpose we are extending the `<Document />` and injecting the server side rendered styles into the `<head>`. For this purpose we wrap the root layout with the [`Provider`](https://styletron.org/api-reference#provider).
## Deploy your own ## Deploy your own
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment