2๐
โ
If I get it right, what you need is to call it with Bracket notation on the window
object like:
window[name]
Source:stackexchange.com