Skip to content

Instantly share code, notes, and snippets.

@sotayamashita
Last active December 3, 2015 07:36
Show Gist options
  • Save sotayamashita/565f404fde62e880ce29 to your computer and use it in GitHub Desktop.
Save sotayamashita/565f404fde62e880ce29 to your computer and use it in GitHub Desktop.
All React Component ports of popular libraries.
.u-contianer {
max-width: 1140px;
width: 0 auto;
}
.c-page-header {
background: #f6f6f6;
color: #777;
}
.c-page-header__top {
border-bottom: 1px solid #eee;
}
.c-page-header__bottom {
padding: 48px 0;
}
.c-page-header__bottom__title {
font-size: 36px;
}
import React, { Component, Proptypes } from 'react';
export class Page extends Component {
render(){
const { title } = this.props;
return(
<div>
<header>
<div className="c-page-header__top">
</div>
<div className="c-page-header__bottom">
<h2 className="c-page-header__bottom__title">{title}</h2>
</div>
<header>
<div>
)
}
}
Page.propTypes = {
title: PropTypes.string.isRequired
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment