Material Design Lite with ReactJS (import/require Issue)
I am trying to use Google's Material Design Lite with ReactJS. I am using Spinner Loading & Text Field Component of MDL library. But, when I switch routes with React Router, the animation does not take place & when I refresh the page, it works fine. I think, this is probably because MDL components are not getting upgraded. Then, I am trying to use componentHandler.upgradeDom() , but Console throws an error, app.js:27160 Uncaught TypeError: Cannot read property 'upgradeDom' of undefined . Here is the code, var React = require('react'); var ReactDOM = require('react-dom'); var PropTypes = React