I am trying to add or change a feature geometry to have some sort of "snap to" functionality. Where if you click and drag an existing feature point, or add a point, you can have it snap to another point if you click and drag closest to another feature. Features will be across multiple different layers as well.
The only way I can imagine this type of functionality is to use identifyLayersWithMaxResults and find the nearest geometry point of the results to set to. Let me know if there is a better way as I think identifyLayersWithMaxResults will not have the performance I require.