I'm trying to assign a value to a field whose name is a value of another field. I expected __e[fieldName]
to work, but it doesn't seem to. I get foo2
, but not foo1

I'm trying to assign a value to a field whose name is a value of another field. I expected __e[fieldName]
to work, but it doesn't seem to. I get foo2
, but not foo1
Hey @Eugene Katz , you'll need to use the JavaScript Object.assign
operator here in order to set the field name. Because of the dynamic nature of the field name value, it can't be created using the name field column
You'd end up with this:
Object.assign(__e, {[__e["fieldName"]]: "bar"})
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.