Skip to content

Implement selective HMR for changed files only #3

@virtualzx-nad

Description

@virtualzx-nad

Original issue from vitejs/vite vitejs#19538

Implement a configuration option to prevent full page reload during HMR and only reload the changed files. This is a complex feature that requires careful consideration of module dependencies and state management.

Required implementation:

  1. Add new configuration option for selective HMR
  2. Implement dependency graph tracking
  3. Add logic to determine minimal reload scope
  4. Handle edge cases like circular dependencies
  5. Add comprehensive tests
  6. Document the feature and its limitations

Considerations:

  • Module boundary detection
  • State preservation
  • Performance impact
  • Edge cases handling

This is an advanced task that requires deep understanding of Vite's HMR system.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions