Minify/Mangle: how to exclude specific variable names from getting mangled?

Hi there,
Is there a way to exclude certain variable names from being mangled when Expo bundles and minifies my app in production mode?
I tried adding the following “reserved” array to the miniferConfig, but it had no effect:

path: node_modules/metro-config/src/defaults/index.js

minifierConfig: {
mangle: {
toplevel: false,
reserved: [“myVariableName”]


  1. SDK Version: 36.0.0
  2. Platforms: Android/iOS

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