In the online search, find two, but there is a difference between the first hand can try.
There is an example of point clustering in the sample code of ArcGIS API for JavaScript. If the URL of 3.18 is https://developers.arcgis.com/javascript/3/jssamples/layers_point_clustering.html
First of all, the first thing to say about ArcGIS, the correct is to download the corresponding zip, the folder will have a corresponding Extras folder, put it in the API folder, such as C:\inetpub\wwwroot\arcgis_js_api\library\3.17\3.17 \extras
You can see the initialization in index.html:
And through Baidu, in GitHub can find the Esri-clusterfeaturelayer, url Https://github.com/odoe/esri-clusterfeaturelayer
The Clusterfeaturelayer is downloaded on GitHub.
You can see the initialization in polytopoint.html:
After viewing the two JS files, it is found that the biggest difference between the two is that Clusterlayer needs data,clusterfeaturelayer URL parameters, that is, the data source is different. The former is a JSON file, while the latter is a featurelayer. Although the effect may finally be consistent, but to correspond ah corresponding!
About the ArcGIS Map Service point Clustering (multipoint cluster display)