This commit is contained in:
yy 2020-08-20 17:38:20 +08:00
commit 06dd158758
1 changed files with 5 additions and 4 deletions

View File

@ -16,11 +16,12 @@ export default class HexagonLayerDemo extends React.Component {
public async componentDidMount() {
const scene = new Scene({
id: 'map',
map: new GaodeMap({
map: new Mapbox({
pitch: 0,
style: 'blank',
center: [140.067171, 36.26186],
zoom: 0,
zoom: 3,
maxZoom: 0,
}),
});
@ -41,7 +42,7 @@ export default class HexagonLayerDemo extends React.Component {
},
transforms: [
{
type: 'hexagon',
type: 'grid',
size: 200000,
field: 'v',
method: 'sum',
@ -51,7 +52,7 @@ export default class HexagonLayerDemo extends React.Component {
.size('sum', (value) => {
return value * 20;
})
.shape('hexagonColumn')
.shape('squareColumn')
.color(
'count',
[