react-use/stories/util/CenterStory.tsx
xobotyi b6993a6f95
feat(prettier): make prettier a part of eslint.
Also reduce max line width to 100. And remove `lint:types` step for
commit sequence, it bothers when committing incomplete (wip) changes.
2021-02-01 18:58:55 +03:00

15 lines
307 B
TypeScript

import * as React from 'react';
export const CenterStory = ({ children }) => (
<div
style={{
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
maxWidth: '400px',
margin: '40px auto',
}}>
<div style={{ width: '100%' }}>{children}</div>
</div>
);