I am facing the following error when I am trying to Import a component in react.
Uncaught TypeError: Cannot read property 'replaceChild' of null at Function.replaceChildWithTree (index_bundle.js:4067) at Object.dangerouslyReplaceNodeWithMarkup (index_bundle.js:21337) at Object.dangerouslyReplaceNodeWithMarkup [as replaceNodeWithMarkup] (index_bundle.js:7162) at ReactCompositeComponentWrapper._replaceNodeWithMarkup (index_bundle.js:22799) at ReactCompositeComponentWrapper._updateRenderedComponent (index_bundle.js:22789) at ReactCompositeComponentWrapper._performComponentUpdate (index_bundle.js:22739) at ReactCompositeComponentWrapper.updateComponent (index_bundle.js:22660) at ReactCompositeComponentWrapper.performUpdateIfNecessary (index_bundle.js:22576) at Object.performUpdateIfNecessary (index_bundle.js:4277) at runBatchedUpdates (index_bundle.js:1846) My Component is:
import React from 'react' export default class NoticeCard extends React.Component { render() { return ( <section className="centered white"> <div className="container section"> <div className="center"> <p>Invalid Username/Password </p> </div> </div> </section> ) } }
The Component is rendered in but the console throws the error.