refactor: convert function expressions to declarations (#4926)

This commit is contained in:
Vladislav Shkodin
2021-02-08 20:01:21 +02:00
committed by GitHub
parent c0236536dd
commit 141a2eba56
241 changed files with 3444 additions and 2933 deletions

View File

@ -30,9 +30,13 @@ function FileContent(props) {
return <FileLink key={value} path={value} href={getAsset(value, field)} />;
}
const FilePreview = props => (
<WidgetPreviewContainer>{props.value ? <FileContent {...props} /> : null}</WidgetPreviewContainer>
);
function FilePreview(props) {
return (
<WidgetPreviewContainer>
{props.value ? <FileContent {...props} /> : null}
</WidgetPreviewContainer>
);
}
FilePreview.propTypes = {
getAsset: PropTypes.func.isRequired,