Skip to content

Latest commit

History

15 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

es-tabify

A function that converts ElasticSearch results into a table data structure. The returned table data structure is similar to that returned by d3-dsv. Inspired by Kibana's tabify implementation. Works with hits style responses as well as nested aggregations.

See also this Python port of this library.

Usage

npm install es-tabify

Here's an example use with the official ElasticSearch JavaScript client.

vartabify=require('es-tabify');varelasticsearch=require('elasticsearch');varclient=newelasticsearch.Client({host: 'localhost:9200',log: 'trace'});client.search({q: 'pants'}).then(function(response){vardata=tabify(response);},function(error){console.trace(error.message);});

Options

Pass in configuration options via object key/value.

var options = { debug: true };
var data = tabify(response, options);
  • debug: (true | false:default) enable output debuging

About

A function that converts ElasticSearch results into a table data structure.

Resources

Stars

10 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages