Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hot reloading is not working (sometimes) #71

Open
codescv opened this issue Feb 10, 2017 · 0 comments
Open

hot reloading is not working (sometimes) #71

codescv opened this issue Feb 10, 2017 · 0 comments

Comments

@codescv
Copy link

codescv commented Feb 10, 2017

change App.js to this:

export default class App extends React.Component {
  constructor(props) {
    super(props);
    this.state = {test: 'foo'};
  }
  render() {
    return (
      <div className={styles.app}>
        {this.state.test}
      </div>
    );
  }
}

then run npm start

now , if we change

return (
      <div className={styles.app}>
        {this.state.test}
      </div>
    );

to

return (
      <div className={styles.app}>
        {this.state.test} hello
      </div>
    );

the browser refreshes correctly.

but if we change

this.state = {test: 'foo'};

to

this.state = {test: 'bar'};

the browser content does not refresh although in console you can see some logging in the console stating that it is refreshing.

not sure if this is a bug in the middleware or configuration though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant