Skip to content

Instantly share code, notes, and snippets.

@ahamedali95
Created November 5, 2019 17:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ahamedali95/ff58e538265a41fa43641ebaa826e05e to your computer and use it in GitHub Desktop.
Save ahamedali95/ff58e538265a41fa43641ebaa826e05e to your computer and use it in GitHub Desktop.
const CommonAlert = props => {
return (<Alert kind={props.kind} show={props.isAlertShown}>{props.message}</Alert> );
}
const SomePageUsingCommonAlert = () => {
return (
<div>
<CommonAlert kind={} isAlertShown={} message={} />
</div>
);
}
const SomePageNotUsingCommonAlert = () => {
return (
<div>
<Alert kind='very-serious' show={!!null}>very-very-very-serious-immediate-action-required</Alert>
</div>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment