@samitouri / QOS-React-2 / commits / 0447f1e792

Update index.html

getting rid of magic numbers

Ilya Shuklin committed Apr 14, 2015 at 16:55 UTC 0447f1e792485ce2dddb4006a4de7ce50b85497c
1 file changed +2 -2
examples/transitions/index.html
+2 -2
@@ -54,10 +54,10 @@
54 var children = [];
55 var pos = 0;
56 var colors = ['red', 'gray', 'blue'];
57 - for (var i = this.state.current; i < this.state.current + 3; i++) {
57 + for (var i = this.state.current; i < this.state.current + colors.length; i++) {
58 var style = {
59 left: pos * 128,
60 - background: colors[i % 3]
60 + background: colors[i % colors.length]
61 };
62 pos++;
63 children.push(<div key={i} className="animateItem" style={style}>{i}</div>);