Javascript – How can I fix code for a simple array. I created a constructor by using key word:new I run code and get: ReferenceError: Products not defined
I'm working out of a text book JavaScript All-In_One. I'm following the directions to write an array. I'm using vscode. This is my array: const list = new Products['eggs','milk','cheese','garlic','onion','kale','salt','pepper']; When I run visual studio I get the error. Products not…