0

I'm trying to set a var string to the name of my array object (see newName). But if I use the code below the arrayobject is named "newName" instead of "test". Can somebody help me out?

var newName = "test"    
var productData = {
  newName : index,
  "productName" : productName,
  "currentInventory" : currentInventory,
  "lastModified" : lastModified
 }
Federico klez Culloca
  • 26,308
  • 17
  • 56
  • 95
Bram van de Munt
  • 51
  • 1
  • 1
  • 4

0 Answers0