zooid-error-state
v1.3.0
Published
ErrorState
Downloads
6
Readme
zooid-error-state
Install
npm install --save zooid-error-state
Props
| Prop | Type | Default | Description | | ----------- | -------| --------| -----------------------------------------------------| | buttonText | string | | Text to display in the primary action (optional) | | className | string | | Additional css classes to merge into the component | | description | string | | Text explaining the cause of the error | | href | string | | URL for the primary action to link to | | onClick | func | | Called when the primary action is clicked (optional) | | title | string | | Title of the error |
Note
For the button to render, a truthy buttonText
value and either an onClick
or href
value must be specified.
Example
import ErrorState from 'zooid-error-state'
export default class App extends Component {
render() {
return (
<ErrorState
title="Sample Error"
description="Something has gone terribly wrong"
buttonText="Continue"
onClick={action('onClick')} />
)
}
}