Skip to content

Vite: Rollup failed to resolve import "drizzle-orm" #325

@ansbar

Description

@ansbar

Hi, we still get the Rollup failed to resolve import "drizzle-orm" error when building our projects.

We use the fixed version 7.3.1. and aren't using RateLimiterDrizzle anywhere in our projects.

If I comment out the following in node_modules it works:

try { // Use dynamic import to prevent static analysis tools from detecting the import const drizzleOrm = await import('drizzle-orm'); const { and, or, gt, lt, eq, isNull, sql } = drizzleOrm.default || drizzleOrm; drizzleOperators = { and, or, gt, lt, eq, isNull, sql }; return drizzleOperators; } catch (error) { throw new RateLimiterDrizzleError( 'drizzle-orm is not installed. Please install drizzle-orm to use RateLimiterDrizzle.' ); }

We import like this:
import { RateLimiterMemory } from 'rate-limiter-flexible'

We actually havent got the problem in the application (a npm package) where we import it but we get the error in all applications that import that package..

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions