Important Things in JavaScript Which is Boost you.

Minhazul Abedin
1 min readMay 6, 2021

You should learn about the best commenting method & coding style, error handling technique, user input with prompt

1. Best Commenting Method in JavaScript :

comments used to explain your code. If using comments in coding, sometimes makes your code more readable. & sometimes it makes you bored & angry for reading that code. Two types of coding in javaScript. there are Single-line comments & multi-line comments.

a. Single-line comments: it’s a comment in the same line. no line breaking in the comment. It’s used for short information of small blocks, function usage, important solutions. commenting method : (//write your comment)

b. Multi-line comments: If you need one more line or multiline comment you can use this method. It has no restriction about lines. It’s used for the overall architecture, high-level view. commenting method: (start with /* your comment end with */).

2. Best Coding style in JavaScript:

coding style representing you what you can & what you do. You can do everything, but if your code doesn’t have readability if your coding format is bad. then most of the cases your value is zero. so, you must learn the best coding style & represent yourself as a smart pregrammer.

a. Curly Braces: Inside of conditional-statement & function, if code is a single-line only. then not need to use curly braces or creating new blocks.

b. Line breaking:

--

--