1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
next.js/packages/next-server/lib
Jayden Seric 49fea51f34 Fix Head.propTypes (#6020)
This PR fixes the buggy `Head.propTypes` here:

https://github.com/zeit/next.js/blob/v8.0.0-canary.3/packages/next-server/lib/head.js#L107

Currently, `Head.propTypes` allows one child node like this:

```jsx
import Head from 'next/head'

// …

<Head>
  <title>Title</title>
</Head>
```

But more than one child node mistakenly causes a prop type error like this:

```jsx
<Head>
  <title>Title</title>
  <meta name="description" content="Description." />
</Head>
```

```
Warning: Failed prop type: Invalid prop `children` supplied to `Head`.
```
2019-01-10 12:53:43 +01:00
..
router Replace event-emitter.js by mitt (#5987) 2019-01-04 21:49:21 +01:00
asset.js Don’t bundle next/asset if it’s not used (#5971) 2018-12-31 19:05:34 +01:00
constants.js Fix linter (#5350) 2018-10-20 17:00:01 +02:00
dynamic.js Remove flow types (#5704) 2018-11-21 16:04:37 +01:00
head.js Fix Head.propTypes (#6020) 2019-01-10 12:53:43 +01:00
loadable-capture.tsx Convert render.js to typescript (#5869) 2018-12-13 01:00:46 +01:00
loadable.js Convert render.js to typescript (#5869) 2018-12-13 01:00:46 +01:00
mitt.ts Replace event-emitter.js by mitt (#5987) 2019-01-04 21:49:21 +01:00
runtime-config.js next-server (#5357) 2018-10-02 00:55:31 +02:00
side-effect.js next-server (#5357) 2018-10-02 00:55:31 +02:00
utils.js Use Typescript to transpile Next.js core files instead of Babel (#5747) 2018-11-28 15:03:02 +01:00