Passed
Pull Request — master (#138)
by
unknown
04:25
created

Component.render   A

Complexity

Conditions 1

Size

Total Lines 4
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 4
c 0
b 0
f 0
rs 10
cc 1
1
import React from 'react';
2
import PropTypes from 'prop-types';
3
import styled from 'styled-components';
4
5
export class Component extends React.PureComponent {
6
  static propTypes = {
7
    className: PropTypes.string,
8
    children: PropTypes.oneOfType([
9
      PropTypes.arrayOf(PropTypes.node),
10
      PropTypes.node,
11
    ]),
12
  };
13
14
  static defaultProps = {
15
    children: null,
16
  };
17
18
  render() {
19
    const { className, children } = this.props;
20
    return <div className={className}>{children}</div>;
21
  }
22
}
23
24
export default styled(Component)`
25
  font-family: 'Helvetica', sans-serif;
26
`;
27