I want to define several interfaces in their own file in my typescript-based project, from which I\'ll implement classes for production as well as mocks for testing. However
You need to export the interface from the file in which is defined and import it wherever you want to use it.
in IfcSampleInterface.ts:
export interface IfcSampleInterface {
key: string;
value: string;
}
In SampleInterface.ts
import { IfcSampleInterface } from './IfcSampleInterface';
let sampleVar: IfcSampleInterface;