Skip to content

Unclear $lib error message #16628

Closed

Description

@teemingc

When migrating from a Kit 2 app that has $lib imports you'll get

During development:

Internal server error: Cannot find module '$lib/images/github.svg' imported from ...

During build:

error during build:
Build failed with 1 error:

Error: [vite]: Rolldown failed to resolve import "$lib/images/svelte-welcome.png" from ...

We can probably make it more obvious about what to do here (unless it's too much trouble) by linking or instructing the user on how to move to #lib instead

Activity

  1. added this to the 3.0 milestone on Aug 3, 2026
  2. self-assigned this
    on Aug 3, 2026
  3. added a commit that references this issue on Aug 4, 2026
    7fb611f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions