Typescript version 2.2.2
I wrote this require in my UserRoutzr.ts
const users = <IUser[]> require(path.join(process.cwd() + "/data"));
TSLint is raising the following warning:
require statement not part of an import statement
if I changed it to :
import users = <IUser[]> require(path.join(process.cwd() + "/data"));
Then it's raising an error :
TS1003 Identifier expected
How should I rewrite this require ? thanks for feedback