<div id="app"></div>


<span id="forkongithub"><a href="https://github.com/bgoonz/React_Notes_V3" target="_blank">Fork me on GitHub</a></span>
#forkongithub a {
  background: #000;
  color: #fff;
  text-decoration: none;
  font-family: arial, sans-serif;
  text-align: center;
  font-weight: bold;
  padding: 5px 40px;
  font-size: 1rem;
  line-height: 2rem;
  position: relative;
  transition: 0.5s;
}
#forkongithub a:hover {
  background: #c11;
  color: #fff;
}
#forkongithub a::before,
#forkongithub a::after {
  content: "";
  width: 100%;
  display: block;
  position: absolute;
  top: 1px;
  left: 0;
  height: 1px;
  background: #fff;
}
#forkongithub a::after {
  bottom: 1px;
  top: auto;
}
@media screen and (min-width: 800px) {
  #forkongithub {
    position: absolute;
    display: block;
    top: 0;
    right: 0;
    width: 200px;
    overflow: hidden;
    height: 200px;
    z-index: 9999;
  }
  #forkongithub a {
    width: 200px;
    position: absolute;
    top: 60px;
    right: -60px;
    transform: rotate(45deg);
    -webkit-transform: rotate(45deg);
    -ms-transform: rotate(45deg);
    -moz-transform: rotate(45deg);
    -o-transform: rotate(45deg);
    box-shadow: 4px 4px 10px rgba(0, 0, 0, 0.8);
  }
}
// class Article extends React.Component {
//   render() {
//     return (
//       <div>
//         <Header title="My Awesome Dogs" />
//         <Author name="Bgoonz" />
//       </div>
//     );
//   }
// }

// class Header extends React.Component {
//   render() {
//     const title = this.props.title;
//     return <h1 className="header">{title}</h1>;
//   }
// }

// class Author extends React.Component {
//   render() {
//     const name = this.props.name;
//     return <p className={`m-${name}`}>{name}</p>;
//   }
// }



const Article = () => <div>
        <Header title="My Awesome Dogs" />
        <Author name="Bgoonz" />
      </div>;
class Header extends React.Component {
  render() {
    const title = this.props.title;
    return <h1 className="header">{title}</h1>;
  }
}

const Author = props => {
  const name = props.name;
  return <p className={`m-${name}`}>{name}</p>;
};
ReactDOM.render(<Article />, document.getElementById("app"));

View Compiled

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

  1. https://fb.me/react-15.1.0.min.js
  2. https://fb.me/react-dom-15.1.0.min.js