I am trying to get a control id by name using JavaScript, similar to "deviceManager.control("control path")" in Lua.

I noticed that there is a deviceManager.controls function for JS but I don't see any documentation for the JS version.

So my question is, how would I find the control id of a control using JS?