fix linting + code syntax for statless components

This commit is contained in:
August Skare
2018-11-16 11:05:30 +01:00
parent 5afef5fe82
commit 54bd7df900
36 changed files with 838 additions and 837 deletions

View File

@@ -1,15 +1,16 @@
import * as React from 'react';
import styled from 'styled-components';
import { colors } from '../variables';
interface InlineCodeProps {
alt?: boolean;
isAlt?: boolean;
children: React.ReactNode;
}
const InlineCode = styled(({ alt, children, ...props }: InlineCodeProps) => <code {...props}>{children}</code>)`
background-color: ${props => (props.alt ? '#E5E8E9' : colors.blueGray)};
const InlineCode = styled(({ isAlt, children, ...props }: InlineCodeProps) => <code {...props}>{children}</code>)`
background-color: ${props => (props.isAlt ? '#E5E8E9' : colors.blueGray)};
padding: 0.3125rem;
`;
export default InlineCode;
export { InlineCode };