Skip to content

Commit

Permalink
changes to readme files
Browse files Browse the repository at this point in the history
  • Loading branch information
dariuszlacheta committed Feb 15, 2019
1 parent 2c3a064 commit dfff397
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 7 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -639,7 +639,7 @@ chart
.render(customParser(result));
```

### Parsing values of each column in Table
### Mapping values of a table column

```javascript
const chart = new KeenDataviz({
Expand All @@ -648,7 +648,7 @@ const chart = new KeenDataviz({
table: {
mapValues: {
'keen.timestamp': (value) => {
return value;
return value.toUpperCase();
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ Types like "bar" and "line" support [axis rotation](http://c3js.org/samples/axes

* metric

Will display results and if `previousResults` are set, show the difference between them.
If `previousResults` is set, the metric will show the difference between the current result and the previous one.

```javascript
const chart = new KeenDataviz({
container: '#some_container',
type: 'metric',
results,
previousResults
previousResults // optional
})
```

Expand Down
3 changes: 2 additions & 1 deletion lib/libraries/default/table.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,8 @@ function _generateTableRows(datavizInstance, dataset) {
continue;
}
if(checkArray[index]){
html += `<td>${mapValues[checkArray[index]](rowCol)}</td>`;continue
html += `<td>${mapValues[checkArray[index]](rowCol)}</td>`;
continue
}
html += `<td>${rowCol}</td>`
}
Expand Down
2 changes: 0 additions & 2 deletions test/demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -569,8 +569,6 @@ <h3>Timeseries</h3>
results,
previousResults
})
.prepare()
.render(results);

window.table = new KeenDataviz({
container: '.chart-demo-table',
Expand Down

0 comments on commit dfff397

Please sign in to comment.