Closed shaunanoordin closed 8 years ago
@shaunanoordin LGTM, but I've got a suggestion. In ES6, var
is the least informative way of declaring a variable, and let
or const
should be preferred when possible. Here: https://github.com/zooniverse/wildcam-gorongosa-education/blob/mapexplorer-redux-refactor/src/containers/MapExplorer.jsx#L141, as far I can see, both legend
and div
are not reassigned, so I think they should be const
instead of var
.
Thanks for the helpful feedback, @simoneduca ! I've gone through the Map Explorer code and improved the use of const
and let
across a few components. This PR is now ready for review!
👍
Closes #104
The Map Explorer was originally built on (a very convoluted implementation of) the basic React patterns. As the project has progressed however, we've embraced the new Redux-React patterns which makes storing data (and communicating data between components) much more easier.
This refactor attempts to:
I'm still in the process of making the code lighter & easier, so shout if you have any suggestions.