mdthansil
mdthansil
Explore posts from servers
KKysely
Created by mdthansil on 6/8/2023 in #help
How can I use Kysely migration inside NextJS 13 project?
Fixed the issue by replacing ts-node with tsx and also changed migrationFolder path to absolute path
const migrator = new Migrator({
db,
provider: new FileMigrationProvider({
fs,
path,
migrationFolder: path.resolve(path.join(__dirname, 'migrations')),
}),
});
const migrator = new Migrator({
db,
provider: new FileMigrationProvider({
fs,
path,
migrationFolder: path.resolve(path.join(__dirname, 'migrations')),
}),
});
3 replies
KKysely
Created by Meithz (Razioner) on 4/2/2023 in #help
Trouble running migrations
Use tsx instead of ts-node and use absolute path for migrationFolder
const migrator = new Migrator({
db,
provider: new FileMigrationProvider({
fs,
path,
migrationFolder: path.resolve(path.join(__dirname, 'migrations')),
}),
});
const migrator = new Migrator({
db,
provider: new FileMigrationProvider({
fs,
path,
migrationFolder: path.resolve(path.join(__dirname, 'migrations')),
}),
});
77 replies
KKysely
Created by mdthansil on 6/7/2023 in #help
How can i enable postgres Extensions (eg: uuid) with in Kysely Migration File
Wow! Thanks man ❤️
4 replies