cdegrel
cdegrel
Explore posts from servers
CDCloudflare Developers
Created by cdegrel on 10/5/2024 in #workers-help
Use PGLite with Wrangler for local development
Hi everyone, For context, I develop an API with HonoJS and Drizzle. For my local development, I'd like to use PGLite. Database migration works perfectly, I can use Drizzle Studio to see this. However, when I make a query, I already have this error:
export const client = new PGlite('.database')

const users = await client.query('SELECT * FROM users')
console.log('users', users)
export const client = new PGlite('.database')

const users = await client.query('SELECT * FROM users')
console.log('users', users)
✘ [ERROR] Error: [unenv] fs.mkdirSync is not implemented yet!
✘ [ERROR] Error: [unenv] fs.mkdirSync is not implemented yet!
Is it possible to use PGLite with wrangler? If anyone can help me with this 🙂
3 replies