Deployment failed! Got error: Your Worker exceeded the size limit of 1 MiB
Why do I get this "Worker" error when deploying my Pages project, even though my entire build output is 428 KiB (20 KiB larger than the Remix template I started with)?
3 Replies
How do I even begin to troubleshoot this? I'm assuming the worker is not just my build directory, so how can I tell what it's size actually is? And why is deploying to a pages project referring me to the Worker documentation?
Because page functions get deployed to a worker
Im not sure how this works with frameworks, but I would assume that anything that runs on the server is packed into the worker
You could run a local build to see the output and double check, there should be a
server
folder or similar in the output directorynpm run build
will tell you exactly how big your worker is