I see in the documentation a Known Limitation placement of labels on polylines.
labelPlacement :
https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-LabelClass.html#labelPlacement
Known Limitation:
Has anyone found a work around for this or am I stuck labeling along the center of my polylines? Ideally I would like to have the option to label above the line or best case perpendicular above as in ArcGIS Pro.
Thanks,
Josh
Hi Josh, unfortunately our line placement options for labels are a bit lacking at the moment -- it's something we've been wanting to address for a while, and I'm hoping we can get to it next release (4.22) or 4.23 at the latest.
Near-term at a bare minimum we'd like to add support for controlling the spacing between line labels, improving line label collision detection, and add above/below & options for curved/uncurved.
@LeonAus in 4.22 we added support for repeatLabel, repeatLabelDistance, allowOverrun, and labelPosition (curve / uncurved). We still don't yet have support for all the different labelPlacement options for polylines yet, but we did get some new people on the team recently, so I'm hoping we'll be able to make more progress in labeling soon! Not specific to lines, but better label centroid placement is something we're working on for next release (4.28).
It seems this limitation is still in place, are there any plans to add the bare minimum functionality in a specific release?
@JoshKlaus333 one solution in the near term is to publish a vector tile cache from ArcGIS pro. This method supports advanced labelling and you still have queryable features, which are actually better performing, dependent on your needs of course
Thanks for the quick response. I will look forward to the update in a future release.
Membros conectados podem postar, seguir atualizações e mais. Novo aqui? Registre uma conta gratuita.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.