
Product
Introducing Webhook Events for Alert Changes
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.
metro-minify-obfuscator
Advanced tools
A metro minifier based on javascript-obfuscator for React Native
yarn add -D metro-minify-obfuscator
or
npm i --save-dev metro-minify-obfuscator
metro.config.js on your projectmodule.exports = {
transformer: {
...
minifierPath: 'metro-minify-obfuscator', // <- add this
minifierConfig: {
defaultMinifierPath: require('metro-minify-uglify'), // required if filter/includeNodeModules options is set, can be metro-minify-uglify or metro-minify-terser dependes on RN version / available installed minifier
filter: (filename) => true, // return true to obfuscate
includeNodeModules: true, // set false to ignore node_modules from obfuscation
trace: false, // show output log
obfuscatorOptions: {
// put additional javscript-obfuscator configuration here
}
},
},
};
minifierConfig properties (⚠️ NOT ALL OPTION IS GUARANTEED WORKING ON REACT-NATIVE, IT MIGHT BREAK YOUR APPS 🙈 )--reset-cache argument to clear metro cache{
"stringArray": false,
"compact": true,
"controlFlowFlattening": true,
"controlFlowFlatteningThreshold": 0.75,
"identifierNamesGenerator": "hexadecimal",
"numbersToExpressions": true,
"splitStrings": true,
"splitStringsChunkLength": 3,
"transformObjectKeys": true,
"simplify": true,
"disableConsoleOutput": true,
"log": false,
"selfDefending": true,
"unicodeEscapeSequence": true
}
--minify true it will shown that code looks doesn't obfuscated// before
module.exports = {
transformer: {
...
minifierPath: 'metro-minify-obfuscator', // <- add this
minifierConfig: {
// put additional javscript-obfuscator configuration here
},
},
};
// after
module.exports = {
transformer: {
...
minifierPath: 'metro-minify-obfuscator', // <- add this
minifierConfig: {
defaultMinifierPath: require('metro-minify-uglify'), // required if filter/includeNodeModules options is set, can be metro-minify-uglify or metro-minify-terser dependes on RN version / available installed minifier
filter: (filename) => true, // return true to obfuscate
includeNodeModules: true, // set false to ignore node_modules from obfuscation
trace: false, // show output log
obfuscatorOptions: {
// put additional javscript-obfuscator configuration here
}
},
},
};
metro-minify-uglify configured with JSO libraryFAQs
🔐 Minifier for Metro based on javscript-obfuscator.
The npm package metro-minify-obfuscator receives a total of 155 weekly downloads. As such, metro-minify-obfuscator popularity was classified as not popular.
We found that metro-minify-obfuscator demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.

Security News
ENISA has become a CVE Program Root, giving the EU a central authority for coordinating vulnerability reporting, disclosure, and cross-border response.

Product
Socket now scans OpenVSX extensions, giving teams early detection of risky behaviors, hidden capabilities, and supply chain threats in developer tools.