Skip to content
This repository was archived by the owner on Mar 19, 2026. It is now read-only.
This repository was archived by the owner on Mar 19, 2026. It is now read-only.

react-moment reporting errors since rolldown-vite 7.1.19 #519

@adhami3310

Description

@adhami3310

Describe the regression

React-moment (alongside setting resolve.mainFields) used to work until rolldown-vite 7.1.19

Reproduction

https://github.com/adhami3310/react-moment-rolldown-repro

Expected Behavior

It displays a date

Actual Behavior

It errors in the browser console with:

Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object.

Check the render method of `Component`.

Steps to Reproduce

bun install followed by bun run dev, although i verified npm has this problem as well

System Info

System:
    OS: Linux 6.17 Arch Linux
    CPU: (16) x64 AMD Ryzen 9 7940HS w/ Radeon 780M Graphics
    Memory: 47.53 GB / 58.66 GB
    Container: Yes
    Shell: 4.2.1 - /bin/fish
  Binaries:
    Node: 25.2.1 - /usr/bin/node
    npm: 11.6.3 - /usr/bin/npm
    bun: 1.3.2 - /usr/bin/bun
    Deno: 2.5.6 - /usr/bin/deno
  npmPackages:
    rolldown-vite:  7.2.7

Used Package Manager

bun

Logs

No response

Validations

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions