In my Web API project, I am using TypeLite to generate Typescript interfaces from C# POCOs. The resulting file looks like this:
// TypeLite.Net4.d.ts
declare namespace MyNamespace.Models {
interface InvoiceModel {
billingPeriodId: number;
createdDate: Date;
invoiceId: number;
invoiceNumber: number;
organizationId: number;
paidDate: Date;
total: number;
}
}
Now, I want to utilize this file in my Angular project, but I'm struggling to find a clear explanation on how to do it. Despite trying various methods found online, such as adding it to my tsconfig.json
in the files
, include
, or typeRoots
sections, I still can't get it to work. Every attempt results in the error message
TS2304: Cannot find name 'InvoiceModel'
. How exactly should I go about incorporating it?