I have several classes in all.ts
module:
export class TemperatureSensor {
temperature: number;
}
export class Chasis {
id: string;
type: string;
ambientTemperature: TemperatureSensor
}
export class Computer {
model: string;
serial: string;
chasis: Chasis;
}
In another module I need to import all of them - I use
import * as models from 'all';
And I can access classes with new models.Computer()
as the example.
Quesion: how can I import all classes from all.ts
without namespace? So I'd like to use new Computer()
?