Skip to content

Simplify pretty-format and inspect #9582

@sheremet-va

Description

@sheremet-va

Clear and concise description of the problem

Vitest currently uses two different libraries to print the text which increases its size for no apparent benefit (is there one?):

  • @vitest/pretty-format for anything test related (like diff or snapshots)
  • @vitest/utils/display for logs (which bundles loupe)

Suggested solution

  1. Use pretty-format for logs.
  2. Consider removing non-essential plugins as a breaking change (react, immutable, dom), or adding them conditionally (in happy-dom, jsdom)

Alternative

No response

Additional context

No response

Validations

Metadata

Metadata

Assignees

No one assigned

    Labels

    p2-nice-to-haveNot breaking anything but nice to have (priority)

    Projects

    Status

    Approved

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions