Create Plotly bundle to load only choropleth

lint
This commit is contained in:
seotts 2021-03-01 11:23:59 -05:00
parent f9864e8351
commit ec3a205dea

View file

@ -1,4 +1,14 @@
import Plot from 'react-plotly.js';
const Plotly = require('plotly.js/lib/core');
// Load in the trace type for choropleth
Plotly.register([
require('plotly.js/lib/choropleth')
]);
// create plotly bundle that only has choropleth plots
import createPlotlyComponent from 'react-plotly.js/factory';
const Plot = createPlotlyComponent(Plotly);
const React = require('react');
const PropTypes = require('prop-types');