{"size": 442, "ext": "js", "max_stars_repo_path": "src/components/UI/Alerts/ErrorAlert/Alert.js", "max_stars_repo_name": "CrispiestHashbrown/tunestumbler_forreddit_app", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/components/UI/Alerts/ErrorAlert/Alert.js", "max_issues_repo_name": "CrispiestHashbrown/tunestumbler_forreddit_app", "max_issues_repo_issues_event_min_datetime": "2021-03-02T00:28:26.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-08T22:58:05.000Z", "max_forks_repo_path": "src/components/UI/Alerts/ErrorAlert/Alert.js", "max_forks_repo_name": "CrispiestHashbrown/tunestumbler-for-reddit", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": 8, "max_forks_count": null, "avg_line_length": 19.2173913043, "max_line_length": 49, "alphanum_fraction": 0.4683257919}
import React from 'react';

import { Alert } from 'react-bootstrap';

const alert = (props) => {
    let alertElement = null;
    if (props.errorMessage) {
        alertElement = 
            <Alert variant="danger" role="alert">
                <p>
                    {props.errorMessage}
                </p>
            </Alert>;
    }

    return (
        <div>
            {alertElement}
        </div>
    );
};

export default alert;