Plot show up empty

I’m trying to integrate Plotly.js into my GWT (formerly Google Web Toolkit) application.
I can generate the charts I need in a standalone HTML file and everything works just fine.
If I then try and include them in the GWT application, the chart shows up empty.

I then went back and used one of the example charts ( and just pasted that into my code and it still shows up empty.

There are no errors in the console.
Unfortunately, I cannot provide a reproducible example, because I’m using GWT. The code I’m using though is here:

private native void jsni(String id) /*-{
	$wnd.Plotly.d3.csv('', function(err, rows){

		function unpack(rows, key) {
			return { return row[key.replace('.',' ')]; });

		colors = [];
		for (i=0; i < unpack(rows, 'class').length; i++) {
			if (unpack(rows, 'class')[i] === "Iris-setosa") {
			} else if (unpack(rows, 'class')[i] === "Iris-versicolor") {
			} else if (unpack(rows, 'class')[i] === "Iris-virginica") {

		var pl_colorscale=[
			[0.0, '#19d3f3'],
			[0.333, '#19d3f3'],
			[0.333, '#e763fa'],
			[0.666, '#e763fa'],
			[0.666, '#636efa'],
			[1, '#636efa']

		function axis() {
			return {
				showline: false,
				zeroline: false,
				gridcolor: '#ffff',
				ticklen: 4

		var data = [{
			type: 'splom',
			dimensions: [
				{label:'sepal length', values:unpack(rows,'sepal length')},
				{label:'sepal width', values:unpack(rows,'sepal width')},
				{label:'petal length', values:unpack(rows,'petal length')},
				{label:'petal width', values:unpack(rows,'petal width')}
			text: unpack(rows, 'class'),
			marker: {
				color: colors,
				size: 7,
				line: {
					color: 'white',
					width: 0.5

		var layout = {
			title:'Iris Data set',
			height: 800,
			width: 800,
			autosize: false,
			plot_bgcolor:'rgba(240,240,240, 0.95)',

		$wnd.Plotly.react(id, data, layout)


Note that the $wnd. is a GWT requirement for accessing globally defined variables.

The chart is fully functional (zoom, pan, etc), but there just isn’t any data. Interestingly, since this is the SPLOM example, there’s also only a single set of axis and not the whole grid. It’s almost like the layout and data are ignored, which also seemed to be the case in the custom charts that I tried to integrate originally.

I originally posted this on GitHub, but it was suggested to post it here to get some feedback from other potential GWT developers or anyone who may be able to help.

Any help is appreciated!