DataGridXL - API

DataStreamer

Description

The DataSteamer (beta) adds JSON streaming features to your DataGridXL instance, to display 500,000 rows in your data grid without blocking page load.

NOTE: This class is in beta and should not be used in production.

Usage

Your DataGridXL instance contains a property dataStreamer. (Only when the streamer option is used.)

javascript
// create DataGridXL instance
const grid = new DataGridXL(...);
// work with the DataStreamer instance
grid.dataStreamer.fetchStream((batch) => ...);
grid.dataStreamer.events.on('complete', ...);
NOTE: You don't need to create a DataStreamer instance yourself — it is provided by the grid automatically.

Methods

fetchStream(onBatch): Promise<boolean>

Fetch stream

Arguments

onBatch
functionCallback function to handle batch
ReturnsPromise<boolean>Resolves when the stream has completed
Fires$start$end

Events

completeDataStreamerEvent

Fired when data stream is complete

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
DataStreamer
Instance that fired the event
startDataStreamerEvent

Fired when data stream starts

Payload

type
string
Type of the event (e.g. 'dblclick', 'contextmenu')
target
DataStreamer
Instance that fired the event