buzyraccoon
DTDrizzle Team
•Created by buzyraccoon on 11/27/2024 in #help
Import problem with drizzle-kit generate
I'm migrating from TypeORM to Drizzle in my Node.js project to manage player data, but I'm facing an issue. I have created schemas in a folder to manage all of them, for example, core/schemas/*.schema.ts.
Some schemas need to use interfaces or types from my project or platform node modules. For example, I created a custom type for Vector3 from alt-server as follows:
Custom type code:
Schema code:
When I run drizzle-kit generate to generate SQL files for all the schemas, I get the following error:
Even if I use declare module or define the Vector3 class directly in the schema, I still encounter this issue when importing custom interfaces from other places. In short, I am unable to import external code.
3 replies