AnsweredAssumed Answered

Javascript API 4.X Clear Highlights

Question asked by shawnroberts on Apr 1, 2019
Latest reply on Apr 2, 2019 by rscheitlin

Hi all, I've got a custom web map that has a side table of the features available on the map. When the user hovers on one of the rows in the side table it highlights the related feature (or multiple) on the map. It's following the logic of, just modified to fit my use case. 


My question is there a more efficient way to remove all of the highlights every time than loop through and use highlight.remove(); ex is there a clear all highlights argument or something that I can pass into remove all highlights out of the layer.


Just looking for the cleanest way possible.