You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
316 B
15 lines
316 B
import {
|
|
FormattedMessage,
|
|
FormattedDate,
|
|
FormattedRelative
|
|
} from 'react-intl';
|
|
|
|
const RelativeTimestamp = ({ timestamp }) => {
|
|
return <FormattedRelative value={new Date(timestamp)} />;
|
|
};
|
|
|
|
RelativeTimestamp.propTypes = {
|
|
timestamp: React.PropTypes.string.isRequired
|
|
};
|
|
|
|
export default RelativeTimestamp;
|
|
|