I am new to typescript and need help getting a thrift-generated module to import into my Angular 7 project. I get an error when I compile:
ERROR in src/app/user.service.ts(5,33): error TS2306: File '/Users/xxxx/projects/tct-client/src/app/gen-js/TestModule_types.d.ts' is not a module.
The thrift:
namespace js Test
struct TestModuleClass
{
1: required string somestring
}
The generated typescript:
declare module Test {
class TestModuleClass {
somestring: string;
constructor(args?: { somestring: string; });
}
}
The import line:
import { TestModuleClass } from './gen-js/TestModule_types';
Thanks in advance for any help here!