Comments (2)
Hey Sara,
Absolutely! I guess I overlooked licensing, given I never thought someone would want the code... but go for it - glad to help.
The plot and the legend are all contained within the RinkChart.js component. The 'rink' itself is just CSS putting a background image on a recharts graph.
The main data passed to the component is the 'allPlays' part of the response from the NHL API. My intermediate API for cutting down the response was really more for learning than practicality, but you can use it here: https://react-nhl-server.now.sh/game/{game-id-here}
I'll look to add comments to the component to make your life easier, as the getCoords function does a number of things which may seem confusing.
Lemme know if you have any questions! Happy to help.
from react-nhl.
Thanks so much! Great stuff. I also have an intermediary to their API, it's not the friendliest thing ever 😄 I'll let you know if I have any more questions!
If you're interested, I'll be posting to this repo once I get some more things going.
from react-nhl.
Related Issues (1)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-nhl.