You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
the problem is, that by the build, the process needs round about 2GB.
for testing purpose, i've removed the "transformLibraries: ['@mui/material']" and the output was round about 600MB.
Expected behavior
the build process should not take up too much memory
Depends on the imports. Although even for that, 2gb is too high. How are you importing ? Is it top-level import, like import {stuff} from '@mui/material' or import stuff form '@mui/material/subpath' ?
But in the context of Pigment CSS, it'll be slower because at the moment, it uses wyw-in-js which uses module evaluation to generate the css. It has it's own code shaking but it's not the same as what you'd get with webpack/vite etc. So when it's a top-level import, it
is essentially evaluating all the imports in that file as well making it slow and memory intensive.
There's an RFC to make it faster, but it'll take time to release and for us to migrate to it.
Steps to reproduce
hi,
i've a nextjs 15.1.0 app and i'm using the withPigment function.
Current behavior
the problem is, that by the build, the process needs round about 2GB.
for testing purpose, i've removed the "transformLibraries: ['@mui/material']" and the output was round about 600MB.
Expected behavior
the build process should not take up too much memory
Context
No response
Your environment
Search keywords: memory peak heap
The text was updated successfully, but these errors were encountered: