Skip to content
Advertisement

How do I fix “Identifier directly after number” error

could anyone tell me what’s wrong with this code and how to fix it? Any help would be appreciated, thanks. The error is: “null – parsing error: Identifier direcly after number”.

JavaScript

Here’s the other code with the error “ChannelId already defined”:

JavaScript

Advertisement

Answer

In JavaScript objects, string values must be wrapped with quotation marks, you can use "string" or 'string'.

This is what your code should look like.

JavaScript

More on JavaScript objects

User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement