I'm not sure why, but while the utils.setUrlParameters utility is supported as an event handler through the GUI, it doesn't seem to be accessible in scripts.
Interestingly, the function specification does appear in the GUI whenever it's used, but when trying to call this utility from a script, it simply doesn’t exist.
Could you clarify why this is the case? Or is there any documentation that might help me use this method directly?
This utility is quite useful for cross-app referencing, especially when reloading the app while ensuring certain variables retain their initial values.
P.s. Added the infamous bug tag, because it seems inconsistent to me.
The main reason this concerns me, is there are times when you're depending on scripts for certain behavior. For instance, when using the app shortcuts, all you can do is use scripts, since there are no event handlers.
In general, using code/scripts can significantly leverage a more Don't-Repeat-Yourself (DRY) workflow.
Finally, I realize there is a openUrl , or openApp, but these act differently and cause the app to reload, or at least parts of it.
Thanks for providing an example, because that's one of the things I wanted to ask: how can I use this regardless of the linter. I guess it's also not mentioned in the docs, as far as I can tell. Something worth considering.
Actually, does this apply to hash or query params?
Ah got it - you can use the following as a good reference. The first argument is an array of query parameters and the second is an array of hash parameters.