

- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to name JavaScript Identifiers?
JavaScript Identifiers are names given to variables, functions, etc. It is the same as identifiers in other programming languages like C, C++, Java, etc. Let’s see identifiers for variable names.
While naming your variables in JavaScript, keep the following rules in mind.
- You should not use any of the JavaScript reserved keywords as a variable name. These keywords are mentioned in the next section. For example, break or boolean variable names are not valid.
- JavaScript variable names should not start with a numeral (0-9). They must begin with a letter or an underscore character. For example, 5demo is an invalid variable name but _5demo is a valid one.
- JavaScript variable names are case-sensitive. For example, Name and name are two different variables.
- Related Questions & Answers
- What are JavaScript Identifiers?
- Identifiers in C++
- What is Perl Identifiers?
- What are Python Identifiers?
- How to name variables in JavaScript?
- What are valid python identifiers?
- What are identifiers in C#?
- What are valid identifiers in Java?
- How to get the code name and product name of the browser in JavaScript?
- Tokens vs Identifiers vs Keywords in C++
- Constructing full name from first name, last name and optional middle name in JavaScript
- JavaScript Error name Property
- Split First name and Last name using JavaScript?
- How to load a JavaScript function using the variable name?
- How to add a class name to an element with JavaScript?
Advertisements