14 lines
234 B
JavaScript
14 lines
234 B
JavaScript
|
import React from 'react';
|
||
|
|
||
|
export default class ImagePreview extends React.Component {
|
||
|
constructor(props) {
|
||
|
super(props);
|
||
|
}
|
||
|
|
||
|
render() {
|
||
|
const { value } = this.props;
|
||
|
|
||
|
return value ? <img src={value}/> : null;
|
||
|
}
|
||
|
}
|