Skip to content

Commit 864e088

Browse files
Fixed examples.
1 parent 0c70f0b commit 864e088

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

Readme.md

+11-9
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ Every `import` you declare gets bundled and served with each page
3030

3131
```jsx
3232
import React from 'react'
33-
import cowsay from 'cowsay'
33+
import cowsay from 'cowsay-browser'
3434
export default () => (
35-
<pre>{ cowsay('hi there!') }</pre>
35+
<pre>{ cowsay({ text: 'hi there!' }) }</pre>
3636
)
3737
```
3838

@@ -46,11 +46,11 @@ We use [Aphrodite](https://github.com/Khan/aphrodite) to provide a great built-i
4646
import React from 'react'
4747
import { css, StyleSheet } from 'next/css'
4848

49-
export default () => {
49+
export default () => (
5050
<div className={ css(styles.main) }>
5151
Hello world
5252
</div>
53-
})
53+
)
5454

5555
const styles = StyleSheet.create({
5656
main: {
@@ -70,11 +70,13 @@ We expose a built-in component for appending elements to the `<head>` of the pag
7070
import React from 'react'
7171
import Head from 'next/head'
7272
export default () => (
73-
<Head>
74-
<title>My page title</title>
75-
<meta name="viewport" content="initial-scale=1.0, width=device-width" />
76-
</Head>
77-
<p>Hello world!</p>
73+
<div>
74+
<Head>
75+
<title>My page title</title>
76+
<meta name="viewport" content="initial-scale=1.0, width=device-width" />
77+
</Head>
78+
<p>Hello world!</p>
79+
</div>
7880
)
7981
```
8082

0 commit comments

Comments
 (0)