Ability to access App Name within retoolContext object

It would be great to be able to access the Retool Application Name in a single universal variable such as an entry within the retoolContext object. Currently the way I have to do this is create a temporary state called appName that houses this javascript: {{ urlparams.href.split('?')[0].split('/')[urlparams.href.split('?')[0].split('/').length - 1] }}. That works fine, but it's messy and somewhat error prone with the copying and pasting across various applications. If it could just be something like {{ retoolContext.appName }} that would be much more convenient.

2 Likes

Hey @Isimon - Plus one on this feature request, I'll surface it internally and see if we would be able to add information like retoolContext.appName, and retoolContext.uuid at some point!

Hey @lsimon!

We've added this property- retoolContext.appName is now immediately available as the full file structure of the name and we will be announcing it in the next changelog on update.retool.com! If you want just name name and not the file structure as well, you would still need to do something like retoolContext.appName.split('/').slice(-1)[0]. Without the full path the appName won't necessarily be unique as you can have the same display name in multiple folders.

image

Great thanks so much for following up here. Looking forward to implementing this as a simpler solution moving forward!

However, in a shared public link the retoolContext.appName is not displayed correctly. There appears a GUID.