Browse Source

feature(global-error): set up global error component

renovate/lint-staged-8.x
Jack Mallers 7 years ago
parent
commit
6e7e4e1cac
  1. 16
      app/components/GlobalError/GlobalError.js
  2. 0
      app/components/GlobalError/GlobalError.scss
  3. 3
      app/components/GlobalError/index.js
  4. 2
      app/routes/app/components/App.js

16
app/components/GlobalError/GlobalError.js

@ -0,0 +1,16 @@
import React from 'react'
import PropTypes from 'prop-types'
import styles from './GlobalError'
const GlobalError = ({ error }) => {
console.log('error: ', error)
return (
<div>
yo global error mf
</div>
)
}
GlobalError.propTypes = {}
export default GlobalError

0
app/components/GlobalError/GlobalError.scss

3
app/components/GlobalError/index.js

@ -0,0 +1,3 @@
import GlobalError from './GlobalError'
export default GlobalError

2
app/routes/app/components/App.js

@ -1,5 +1,6 @@
import React, { Component } from 'react'
import PropTypes from 'prop-types'
import GlobalError from 'components/GlobalError'
import LoadingBolt from 'components/LoadingBolt'
import Form from 'components/Form'
import ModalRoot from 'components/ModalRoot'
@ -37,6 +38,7 @@ class App extends Component {
return (
<div>
<GlobalError />
<ModalRoot
modalType={modalType}
modalProps={modalProps}

Loading…
Cancel
Save