Cannot use template parameter for an entity type
powerpaul17 opened this issue · 1 comments
powerpaul17 commented
I tested with the recent version and unfortunately got a typing error.
The following example fails with an error stating that MyEntity
cannot be assigned to Entity<T>
import { createDB, createTable } from 'blinkdb';
const database = createDB({
clone: false
});
function abc<T extends MyEntity>(): void {
createTable<T>(database, 'test')();
}
type MyEntity = {
id: string;
}
abc();
I don't know how to resolve this..
maradotwebp commented
This has been fixed in v0.13.1, the latest release.