Anybody familiar with this error when compiling a project running sequelize-typescript v 0.6.0-beta.3:
node_modules/sequelize-typescript/lib/models/Model.d.ts(133,129): error TS2693: 'T' only refers to a type, but is being used as a value here.
133 static scope<T extends Model<T>>(this: (new () => T), options?: string | string[] | ScopeOptions | WhereOptions<any>): typeof T;
Plus many others similar to this one.
Is there any settings or configuration setup that I am missing?
@bosunolanrewaju Looks like a bug. typeof T is invalid imo. @schmod or am I wrong?
@bosunolanrewaju What version of typescript are you using?
@Tower540 @bosunolanrewaju can you try again with TS 2.5.3?
That's what we use internally, and it seems to work.
sorry i don't have this error, i was on the bad thread lol
Looks like you need skipLibCheck": true in your .tsconfig.
alright thanks bro! :)
@schmod According to this issue: https://github.com/Microsoft/TypeScript/issues/204 typeof T is not valid unfortunately
@schmod not working still has the same error if the folder is not in
node_modules\@types
@schmod Typescript version is 2.6.1
@RobinBuschmann Ugh, you're right. I don't think we can have typesafety on scopes 馃槩
v0.6.0-beta.4 is released now
Most helpful comment
Looks like you need
skipLibCheck": truein your.tsconfig.