// NPM imports import React, { Component, PropTypes } from "react"; /** * A dismissible Bootstrap alert. */ export default class DismissibleAlert extends Component { render () { // Set correct alert type let alertType = "alert-danger"; if (this.props.type) { alertType = "alert-" + this.props.type; } return (

{this.props.text}

); } } DismissibleAlert.propTypes = { type: PropTypes.string, text: PropTypes.string };