Module in TypeScript || Module Concept

In this video,I explained how to use module in TypeScript. Feel free to comment. For more, please subscribe and press the BELL icon. Please visit my Angular Playlist. Please visit my Angular Videos
The code is as follows -

module.ts - 
import { Point } from './module1';

let point = new Point(30,40);
point.draw();

module1.ts - 
export class Point {
  constructor (private a: number, private b: number) {   }

  draw() {
    console.log('A: - ' + this.a + ' B:- ' + this.b);
  }

}


Comments

Popular posts from this blog

Alert Dialog Box in JS || JavaScript Dialog Box

HTML - Frameset Tag in html

Indian Flag || Indian Flag using HTML CSS