You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 7, 2020. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+23-3Lines changed: 23 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,10 +25,27 @@ You can think of this as a bare bones [jsdom][] that's built to bridge the gap b
25
25
26
26
I'm trying to keep it light so as not to slow down your render function. I want efficient, declarative and stateless code, but I don't want to throw away previous tools to get there.
27
27
28
+
## Limitations
29
+
30
+
It's great for...
31
+
32
+
* Static D3 components or other such libraries (things like Backbone should work too!)
33
+
* D3 components with simple state and event interaction, like tooltips on charts
34
+
* D3 components such as progress bars that can be animated using [react-motion][], for example
35
+
36
+
It's not so great for...
37
+
38
+
* Physics based D3 components or anything using a lot of DOM mutation and state
39
+
* Linked to the previous one, brushing and filtering of selections using the built in stateful D3 tools
40
+
* Essentially: Anything with a lot of DOM mutation from timers, events or internal state will be hard to use
41
+
42
+
If you keep it stateless and React-ish then you'll be fine. Use tools like D3 to fluently build your charts / DOM, don't use it as an animation / physics / DOM mutation library, that doesn't work within React. See the state example linked below for a simple way to handle state, events and D3.
43
+
28
44
## Usage
29
45
30
46
* Full [documentation][] with current DOM API coverage
31
-
* A full example use case can be found [in my lab][lab-post] ([source][lab-source])
47
+
*[An example static chart ][lab-chart] ([source][lab-chart-source])
48
+
*[A simple example using state and events][lab-state] ([source][lab-state-source])
32
49
*[d3-react-sparkline][], a small component I built at [Qubit][]
33
50
34
51
## Development
@@ -64,8 +81,11 @@ Do what you want. Learn as much as you can. Unlicense more software.
0 commit comments