Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

class constructor

class Person {
    constructor(name, age){
        this.name = name;
        this.age = age;
        console.log(this);
    }
}
const person = new Person("YASDASD", 123);

Comment

class constructor syntax

class Rectangle {
  constructor(height, width) {
    this.height = height;
    this.width = width;
  }
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: remove selected bar mui tabs 
Javascript :: finding in mongoose using a name 
Javascript :: express get ip address of request 
Javascript :: round number 2 decimal places javascript 
Javascript :: Clear Cell Value In Google Sheet By App Scripts 
Javascript :: how to find the last item in an array 
Javascript :: jquery empty and append 
Javascript :: replace all dashes to slashes using jquery in a string 
Javascript :: axios configure base url 
Javascript :: oncheck checkbox javascript 
Javascript :: jquery remove style 
Javascript :: javascript compare object arrays keep only entries not in both 
Javascript :: how to validate age above 18 in javascript 
Javascript :: jquery remove keypress event 
Javascript :: regex any letter 
Javascript :: react native open simulators list 
Javascript :: get the parent node from child node 
Javascript :: return index of array with function in array angular 
Javascript :: javascript to help find overflow elements 
Javascript :: Update nextjs to 11 
Javascript :: number validation in javascript 
Javascript :: node js module export class 
Javascript :: javascript use camera 
Javascript :: js encode to & 
Javascript :: create angular app with routing and scss 
Javascript :: activeClassName react router 
Javascript :: datatable column width 
Javascript :: stop from from refresching page react 
Javascript :: how to go to next page on button click js 
Javascript :: javascript get random array of integre in given range 
ADD CONTENT
Topic
Content
Source link
Name
8+5 =