A new item type should be added to Enterprise / Online for the storing and sharing of Arcade expressions. Users would be able to add reusable function(s) / expression(s) and have them accessible to other users in the organization via the Arcade Editor(s) alongside Globals, Functions, Constants. Reusable expressions would be scoped per existing ESRI sharing model and role based access controls.
As of this writing Arcade Expressions must be stored and shared outside of the ArcGIS platform itself. Thus if you've written a helpful, reusable function that may be applied across multiple products / teams you need to store it in a separate platform, communicate to your teammates or users its location and provision access, then copy / paste into each applicable content type (e.g. Dashboard, WebMap) that fits the expression's use case.
Here's a sample workflow:
Developer A writes a reusable function that takes a FeatureSetByPortalItem and returns a new FeatureSet with some aggregated, computed columns. Developer A gives this expression a unique name and saves it as an item type of Expression and shares it at the appropriate level.
Customers B, C, D, assuming that their privileges are scoped to see the Expression Item, would then have access to it inside the Arcade Editor window so that they could drag it into their workflows without having to contact Developer A and/or go outside of ArcGIS Enterprise to access the logic.
Potential Drawbacks:
Many Arcade Expressions are not written in a reusable style. The Arcade Editor window could quickly become cluttered with expressions whose applicability is limited.
Workaround:
Add the sharing of Expression Item Types as an option under Role Based Security and Customization.
Adding to portal would also allow appropriate metadata description that would explain function and use case and tags that make it discoverable.
For sure want this too. I visualize it as a bunch of items called "Arcade Functions" and "Arcade Expressions". 2 different library concepts. Then when I edit and attribute in smart forms I have a Custom Library to pull from. Apply the same code to 50 layers and 5 attributes is 150 times. Fix/find a bug....oh boy that is a lot of changes!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.