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

Example for chartData from web URLs? #22

Open
daluu opened this issue Jan 14, 2016 · 1 comment
Open

Example for chartData from web URLs? #22

daluu opened this issue Jan 14, 2016 · 1 comment

Comments

@daluu
Copy link

daluu commented Jan 14, 2016

I'm new to this project, react, webpack, browserify, and d3. It's nice you have a getting started section that talks a bit about the chart data:

http://www.reactd3.org/get_start/#getting_started

http://www.reactd3.org/get_start/#write_chart (full code in your javascript section)

but it only shows the chart data structure & how you load from CSV/TSV/JSON files. What if the data is dynamic/real time from a URL (REST API, etc.)? As a novice to these JS stacks, I'm not familiar with what is the proper or simple suggested method to load the chart data from URL.

With this stack, is the loading via node.js HTTP request related modules (more like server side with the webpack/browserify bundling translating that to the needed client side equivalent) or via client side XmlHttpRequests (or whatever JS abstractions to that that one uses like jQuery/d3)?

An example of how to load the chart data from a URL would be really useful. With the assumption that the data is already in the proper format that this project requires (and if not, up to the user to reformat it).

@chilijung
Copy link
Contributor

@daluu, react-d3 is based on React. You can find out how to load data via API in react docs, such as https://facebook.github.io/react/tips/initial-ajax.html. I'm pretty busy recently I'll write a demo if I have time.

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

2 participants