Skip to content

Fix SSR external resolution with resolve.alias #2

@virtualzx-nad

Description

@virtualzx-nad

Original issue from vitejs/vite vitejs#19461

Currently, there's an issue where SSR external doesn't work correctly with resolve.alias. This needs to be fixed to ensure proper module resolution during SSR builds.

Steps to reproduce:

  1. Set up a Vite project with SSR
  2. Configure resolve.alias for a module
  3. Mark the module as external for SSR
  4. The module is not properly externalized

Required changes:

  1. Fix the module resolution logic for SSR externals
  2. Handle alias resolution properly
  3. Add test cases
  4. Update documentation if needed

This is a medium complexity issue that requires understanding of Vite's module resolution system.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingssr

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions