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

Real world example does not work on master #2469

Closed
headquarters opened this issue Jun 23, 2017 · 6 comments
Closed

Real world example does not work on master #2469

headquarters opened this issue Jun 23, 2017 · 6 comments

Comments

@headquarters
Copy link
Contributor

  1. Clone the repo on the master branch
  2. cd redux/examples/real-world
  3. npm install
  4. npm start

The real world example fails with the following errors:

./src/containers/App.js
  Line 9:   'propTypes' is not defined           no-undef
  Line 18:  'handleDismissClick' is not defined  no-undef
  Line 23:  'handleChange' is not defined        no-undef

If I pin all the dependencies to the exact version in examples/real-world/package.json, do another npm install, and try again I get similar errors but only reported for UserPage.js.

So this appears to be an issue with the class properties transform not working properly, but I couldn't pinpoint the exact cause. If I figure out a solution I'll put up a PR.

@markerikson
Copy link
Contributor

Those do not appear to be "real" errors, but rather ESLint warnings that are being marked as errors. I think CRA may have somewhat recently decided to enforce some ESLint rules as errors.

Not sure on the right way to take care of this.

@headquarters
Copy link
Contributor Author

Ok, that makes a lot more sense considering everything is actually defined that is reported. When linter errors take over the screen and don't let you actually see the app, though, I still consider them "real". 😄

How about a PR to disable those with /* eslint */ rules in those files?

@headquarters
Copy link
Contributor Author

Some extra information: the example works if you do NOT do yarn or npm install at the top level of the redux repo.

So, if you only install the modules in examples/real-world, it works. If you go up to the root redux folder, install the modules, then go back and reinstall in real-world and re-run the example app then these errors show up.

@markerikson
Copy link
Contributor

Huh. That's... interesting. Some side effect of ESLint config resolution, I guess?

@bbwstar
Copy link

bbwstar commented Jun 23, 2017 via email

@markerikson
Copy link
Contributor

@bbwstar : This is an issue tracker, not a help forum.

That said, I keep a big list of links to high-quality tutorials and articles on React, Redux, and related topics, at https://github.com/markerikson/react-redux-links . Specifically intended to be a great starting point for anyone trying to learn the ecosystem, as well as a solid source of good info on more advanced topics. You should also check out the Reactiflux chat channels on Discord, at https://www.reactiflux.com .

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

3 participants