How to Disable generating sourcemap with expo build:web

I tried with putting

GENERATE_SOURCEMAP=false

in .env file, running command

set \"GENERATE_SOURCEMAP=false\" && expo build:web

and

"build": "GENERATE_SOURCEMAP=false expo build:web"

in scripts inside package.json nothing works. Devtools show my everything.

How can I protect my source from being exposed with expo:build?

I’m running into this problem as well - need to disable sourcemaps on production and the GENERATE_SOURCEMAP flag doesn’t seem to make a difference.

The way I solved the issue is, just deleting every .map files from the deployment folder. It works.
Thanks.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.