1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
next.js/test/integration/production/components/hello-context.js

16 lines
270 B
JavaScript
Raw Normal View History

import React from 'react'
import PropTypes from 'prop-types'
export default class extends React.Component {
static contextTypes = {
data: PropTypes.object
}
render () {
const { data } = this.context
return (
<div>{data.title}</div>
)
}
}