Answer the question
In order to leave comments, you need to log in
How to compile a TypeScript project correctly?
There is the following code in TypeScript:
class A {
a: string;
b: number;
constructor() {
this.a = 'str1';
this.b = 20;
}
}
class B extends A {
c: string;
constructor() {
super();
this.c = 'str2';
}
}
var a: B = new B;
console.log(a);
export class A {
a: string;
b: number;
constructor() {
this.a = 'str1';
this.b = 20;
}
}
import {A} from './a';
class B extends A {
c: string;
constructor() {
super();
this.c = 'str2';
}
}
var a: B = new B;
console.log(a);
exports is not defined
System is not defined
define is not defined
exports is not defined
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question