Some basic concept on Javascript you must know.

Anik Zaman
3 min readMay 5, 2021
  1. Function: Function is a block of code to perform a particular task. Javascript has function like other programming languages. Function may be declared first then we can call at any place. Even function can be anonymous which is used directly as a parameter of another function without declaring it previously. Function can be used recursively. Even a function can be used into another function.
  2. String: String is a type of object in javascript. String holds text even numbers or symbols as a form of text. Any text, word, sentence, number or symbol into quotation mark refers string.
  3. Some method of string: charAt() method returns the position of an individual string in a main string. length() method returns the length of the string. toUpperCase() method convert the string into upper case form. concat() method add to string into one string. trim() method delete unusual space in a string. slice() method returns a part of the main string. replace() method replace substring with another substring.
  4. Array: Array is a type of object in javascript. It holds multiple values in a single variable. Values can be anything like string, number or function. Individual value can be accessed using indexing.
  5. Some method of Array: concat() method joins two or more arrays and return it. Find() method returns the value of the first match from the array. findIndex() method returns the index of first match from the array. forEach() method calls every values of array. pop() method removes the values of the array. push() method adds new values to the end. reverse() method reverse the order of the elements of the array.
  6. Variable: Javascript has three keyword to declare a variable: let, const and var. let allows to declare block level variables. const declares variable that value can not be changed in future. Var allows to declare variable globally that means it is available anywhere.
  7. Number : In javascript there are two types of number: regular number and bigInt numbers. Number holds a numeric value. Javascript represents a number using Number() constructor or directly assign a number to a variable.
  8. Some method of number: isInteger() method checks whether a value is an integer. isNaN() checks whether a value is not a number. toString() converts a number to string. abs() method returns the absolute value of a number. floor() method returns rounded downwards value. ceil() method returns rounded upwards value. sqrt() method returns the square root of a number.
  9. Object: It is one of the data types of javascript. It is used to collect complex entities. Each entity has a key and a value. using Object() constructor or using {} we can create empty object.
  10. SSL certificate: SSL certificates are a small data files that cryptographically establish an encrypted link between a web server and a browser. This link ensures that all data passed between the web server and browser remain private. A website with SSL certificate has URL with “https://” and not “http://”. Even a padlock icon can be seen in the URL bar. SSL certificate has also a benefit for search engine optimization.

--

--