@react-native-community/cli-plugin-metro
Advanced tools
Comparing version 12.0.0-alpha.11 to 12.0.0-alpha.12
{ | ||
"name": "@react-native-community/cli-plugin-metro", | ||
"version": "12.0.0-alpha.11", | ||
"version": "12.0.0-alpha.12", | ||
"description": "[Removed since 12.0.0-alpha.12]", | ||
"license": "MIT", | ||
"main": "build/index.js", | ||
"publishConfig": { | ||
"access": "public" | ||
}, | ||
"dependencies": { | ||
"@react-native-community/cli-server-api": "12.0.0-alpha.11", | ||
"@react-native-community/cli-tools": "12.0.0-alpha.11", | ||
"chalk": "^4.1.2", | ||
"execa": "^5.0.0", | ||
"metro": "0.78.0", | ||
"metro-config": "0.78.0", | ||
"metro-core": "0.78.0", | ||
"readline": "^1.3.0" | ||
}, | ||
"devDependencies": { | ||
"@react-native-community/cli-types": "12.0.0-alpha.11", | ||
"metro-resolver": "0.78.0" | ||
}, | ||
"files": [ | ||
"build", | ||
"!*.map" | ||
], | ||
"homepage": "https://github.com/react-native-community/cli/tree/main/packages/cli-plugin-metro", | ||
@@ -33,3 +15,3 @@ "repository": { | ||
}, | ||
"gitHead": "079150994170816bb332293d3dd118e997651541" | ||
"gitHead": "0c6372c631cea02e7fc5e12a9141e8cea4bb90ba" | ||
} |
209
README.md
# @react-native-community/cli-plugin-metro | ||
This package is part of the [React Native CLI](../../README.md). | ||
It contains commands for managing the Metro bundler. | ||
## Installation | ||
```sh | ||
yarn add @react-native-community/cli-plugin-metro | ||
``` | ||
## Commands | ||
### `start` | ||
Usage: | ||
```sh | ||
react-native start [option] | ||
``` | ||
Starts the server that communicates with connected devices | ||
#### Options | ||
#### `--port <number>` | ||
Specify port to listen on | ||
#### `--projectRoot <path>` | ||
Path to a custom project root | ||
#### `--watchFolders <list>` | ||
Specify any additional folders to be added to the watch list | ||
#### `--assetPlugins <list>` | ||
Specify any additional asset plugins to be used by the packager by full filepath | ||
#### `--sourceExts <list>` | ||
Specify any additional source extensions to be used by the packager | ||
#### `--max-workers <number>` | ||
Specifies the maximum number of workers the worker-pool will spawn for transforming files. This defaults to the number of the cores available on your machine | ||
#### `--transformer <string>` | ||
Specify a custom transformer to be used | ||
#### `--reset-cache, --resetCache` | ||
Removes cached files | ||
#### `--custom-log-reporter-path, --customLogReporterPath <string>` | ||
Path to a JavaScript file that exports a log reporter as a replacement for TerminalReporter | ||
#### `--https` | ||
Enables https connections to the server | ||
#### `--key <path>` | ||
Path to custom SSL key | ||
#### `--cert <path>` | ||
Path to custom SSL cert | ||
#### `--config <string>` | ||
Path to the CLI configuration file | ||
#### `--no-interactive` | ||
Disables interactive mode | ||
### `bundle` | ||
Usage: | ||
```sh | ||
react-native bundle <flag> | ||
``` | ||
Builds the JavaScript bundle for offline use. | ||
#### `--entry-file <path>` | ||
Path to the root JS file, either absolute or relative to JS root. | ||
#### `--platform <string>` | ||
> default: ios | ||
Either "ios" or "android". | ||
#### `--transformer <string>` | ||
Specify a custom transformer to be used. | ||
#### `--dev [boolean]` | ||
> default: true | ||
If false, warnings are disabled and the bundle is minified. | ||
#### `--minify [boolean]` | ||
Allows overriding whether bundle is minified. This defaults to false if dev is true, and true if dev is false. Disabling minification can be useful for speeding up production builds for testing purposes. | ||
#### `--bundle-output <string>` | ||
File name where to store the resulting bundle, ex. `/tmp/groups.bundle`. | ||
If you are planning on building a debug APK, that will run without the packager, by invoking `./gradlew assembleDebug` you can simply set `bundleInDebug: true` in your app/build.gradle file, inside the `project.ext.react` map. | ||
<details> | ||
Alternatively if you want to run <code>react-native bundle</code> manually and then create the APK with <code>./gradlew assembleDebug</code> you have to make sure to put the bundle into the right directory and give it the right name, so that gradle can find it. | ||
For react-native versions 0.57 and above the bundle output path should be: | ||
<code>android/app/build/generated/assets/react/debug/index.android.js</code> | ||
To find out the correct path for previous react-native versions, take a look at the <code>react.gradle</code> file here: <https://github.com/facebook/react-native/blob/0.57-stable/react.gradle> or inside your <code>node_modules/react-native</code> directory. | ||
The expected path for the js bundle can be found on the line that starts with <code>jsBundleDir = </code>. | ||
</details> | ||
#### `--bundle-encoding <string>` | ||
> default: utf8 | ||
Encoding the bundle should be written in (<https://nodejs.org/api/buffer.html#buffer_buffer>). | ||
#### `--max-workers <number>` | ||
Specifies the maximum number of workers the worker-pool will spawn for transforming files. This defaults to the number of the cores available on your machine. | ||
#### `--sourcemap-output <string>` | ||
File name where to store the sourcemap file for resulting bundle, ex. `/tmp/groups.map`. | ||
#### `--sourcemap-sources-root <string>` | ||
Path to make sourcemap sources entries relative to, ex. `/root/dir`. | ||
#### `--sourcemap-use-absolute-path` | ||
> default: false | ||
Report SourceMapURL using its full path. | ||
#### `--assets-dest <string>` | ||
Directory name where to store assets referenced in the bundle. | ||
If you are planning on building a debug APK that will run without the packager, see ([--bundle-output](https://github.com/react-native-community/cli/blob/main/packages/cli-plugin-metro/README.md#--bundle-output-string)) | ||
<details> | ||
Alternatively if you want to run <code>react-native bundle</code> manually and then create the APK with <code>./gradlew assembleDebug</code> you have to make sure to put the assets into the right directory, so that gradle can find them. | ||
For react-native versions 0.57 and above the <code>--assets-dest</code> path should be: | ||
<code>android/app/build/generated/res/react/debug</code> | ||
The expected path for the assets can be found in the react.gradle file on the line that starts with <code>resourcesDir =</code> | ||
</details> | ||
#### `--reset-cache` | ||
> default: false | ||
Removes cached files. | ||
#### `--read-global-cache` | ||
> default: false | ||
Try to fetch transformed JS code from the global cache, if configured. | ||
#### `--config <string>` | ||
Path to the CLI configuration file. | ||
### `ram-bundle` | ||
Usage: | ||
```sh | ||
react-native ram-bundle [options] | ||
``` | ||
Builds JavaScript as a "Random Access Module" bundle for offline use. | ||
#### Options | ||
Accepts all of [bundle commands](#bundle) and following: | ||
#### `--indexed-ram-bundle` | ||
Force the "Indexed RAM" bundle file format, even when building for Android. | ||
> **[Removed]** | ||
> | ||
> This package is now relocated as [`@react-native/community-cli-plugin`](https://github.com/facebook/react-native/tree/main/packages/community-cli-plugin). | ||
> | ||
> To make new contributions to this package, please open a PR in the [React Native repo](https://github.com/facebook/react-native) ([contributing guide](https://github.com/facebook/react-native/tree/main/packages/community-cli-plugin#contributing)). |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Empty package
Supply chain riskPackage does not contain any code. It may be removed, is name squatting, or the result of a faulty package publish.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
0
0
0
2067
3
0
8
2
- Removed@react-native-community/cli-server-api@12.0.0-alpha.11
- Removedchalk@^4.1.2
- Removedexeca@^5.0.0
- Removedmetro@0.78.0
- Removedmetro-config@0.78.0
- Removedmetro-core@0.78.0
- Removedreadline@^1.3.0
- Removed@ampproject/remapping@2.3.0(transitive)
- Removed@babel/code-frame@7.26.2(transitive)
- Removed@babel/compat-data@7.26.2(transitive)
- Removed@babel/core@7.26.0(transitive)
- Removed@babel/generator@7.26.2(transitive)
- Removed@babel/helper-compilation-targets@7.25.9(transitive)
- Removed@babel/helper-module-imports@7.25.9(transitive)
- Removed@babel/helper-module-transforms@7.26.0(transitive)
- Removed@babel/helper-string-parser@7.25.9(transitive)
- Removed@babel/helper-validator-identifier@7.25.9(transitive)
- Removed@babel/helper-validator-option@7.25.9(transitive)
- Removed@babel/helpers@7.26.0(transitive)
- Removed@babel/parser@7.26.2(transitive)
- Removed@babel/runtime@7.26.0(transitive)
- Removed@babel/template@7.25.9(transitive)
- Removed@babel/traverse@7.25.9(transitive)
- Removed@babel/types@7.26.0(transitive)
- Removed@jest/schemas@29.6.3(transitive)
- Removed@jest/types@26.6.227.5.129.6.3(transitive)
- Removed@jridgewell/gen-mapping@0.3.5(transitive)
- Removed@jridgewell/resolve-uri@3.1.2(transitive)
- Removed@jridgewell/set-array@1.2.1(transitive)
- Removed@jridgewell/source-map@0.3.6(transitive)
- Removed@jridgewell/sourcemap-codec@1.5.0(transitive)
- Removed@jridgewell/trace-mapping@0.3.25(transitive)
- Removed@react-native-community/cli-debugger-ui@12.0.0-alpha.11(transitive)
- Removed@react-native-community/cli-server-api@12.0.0-alpha.11(transitive)
- Removed@react-native-community/cli-tools@12.0.0-alpha.11(transitive)
- Removed@sinclair/typebox@0.27.8(transitive)
- Removed@types/istanbul-lib-coverage@2.0.6(transitive)
- Removed@types/istanbul-lib-report@3.0.3(transitive)
- Removed@types/istanbul-reports@3.0.4(transitive)
- Removed@types/node@22.8.4(transitive)
- Removed@types/yargs@15.0.1916.0.917.0.33(transitive)
- Removed@types/yargs-parser@21.0.3(transitive)
- Removedaccepts@1.3.8(transitive)
- Removedacorn@8.14.0(transitive)
- Removedansi-regex@5.0.1(transitive)
- Removedansi-styles@4.3.05.2.0(transitive)
- Removedanymatch@3.1.3(transitive)
- Removedappdirsjs@1.2.7(transitive)
- Removedargparse@1.0.10(transitive)
- Removedasync@3.2.6(transitive)
- Removedbalanced-match@1.0.2(transitive)
- Removedbase64-js@1.5.1(transitive)
- Removedbl@4.1.0(transitive)
- Removedbrace-expansion@1.1.11(transitive)
- Removedbraces@3.0.3(transitive)
- Removedbrowserslist@4.24.2(transitive)
- Removedbser@2.1.1(transitive)
- Removedbuffer@5.7.1(transitive)
- Removedbuffer-from@1.1.2(transitive)
- Removedbytes@3.0.0(transitive)
- Removedcaller-callsite@2.0.0(transitive)
- Removedcaller-path@2.0.0(transitive)
- Removedcallsites@2.0.0(transitive)
- Removedcamelcase@6.3.0(transitive)
- Removedcaniuse-lite@1.0.30001676(transitive)
- Removedchalk@4.1.2(transitive)
- Removedci-info@2.0.03.9.0(transitive)
- Removedcli-cursor@3.1.0(transitive)
- Removedcli-spinners@2.9.2(transitive)
- Removedcliui@8.0.1(transitive)
- Removedclone@1.0.4(transitive)
- Removedcolor-convert@2.0.1(transitive)
- Removedcolor-name@1.1.4(transitive)
- Removedcommander@2.20.3(transitive)
- Removedcompressible@2.0.18(transitive)
- Removedcompression@1.7.4(transitive)
- Removedconcat-map@0.0.1(transitive)
- Removedconnect@3.7.0(transitive)
- Removedconvert-source-map@2.0.0(transitive)
- Removedcore-util-is@1.0.3(transitive)
- Removedcosmiconfig@5.2.1(transitive)
- Removedcross-spawn@7.0.3(transitive)
- Removeddebug@2.6.94.3.7(transitive)
- Removeddefaults@1.0.4(transitive)
- Removeddenodeify@1.2.1(transitive)
- Removeddepd@2.0.0(transitive)
- Removeddestroy@1.2.0(transitive)
- Removedee-first@1.1.1(transitive)
- Removedelectron-to-chromium@1.5.49(transitive)
- Removedemoji-regex@8.0.0(transitive)
- Removedencodeurl@1.0.22.0.0(transitive)
- Removederror-ex@1.3.2(transitive)
- Removederror-stack-parser@2.1.4(transitive)
- Removederrorhandler@1.5.1(transitive)
- Removedescalade@3.2.0(transitive)
- Removedescape-html@1.0.3(transitive)
- Removedesprima@4.0.1(transitive)
- Removedetag@1.8.1(transitive)
- Removedexeca@5.1.1(transitive)
- Removedfb-watchman@2.0.2(transitive)
- Removedfill-range@7.1.1(transitive)
- Removedfinalhandler@1.1.2(transitive)
- Removedfind-up@5.0.0(transitive)
- Removedfresh@0.5.2(transitive)
- Removedfs.realpath@1.0.0(transitive)
- Removedfsevents@2.3.3(transitive)
- Removedgensync@1.0.0-beta.2(transitive)
- Removedget-caller-file@2.0.5(transitive)
- Removedget-stream@6.0.1(transitive)
- Removedglob@7.2.3(transitive)
- Removedglobals@11.12.0(transitive)
- Removedgraceful-fs@4.2.11(transitive)
- Removedhas-flag@4.0.0(transitive)
- Removedhermes-estree@0.15.0(transitive)
- Removedhermes-parser@0.15.0(transitive)
- Removedhttp-errors@2.0.0(transitive)
- Removedhuman-signals@2.1.0(transitive)
- Removedieee754@1.2.1(transitive)
- Removedimage-size@1.1.1(transitive)
- Removedimport-fresh@2.0.0(transitive)
- Removedinflight@1.0.6(transitive)
- Removedinherits@2.0.4(transitive)
- Removedinvariant@2.2.4(transitive)
- Removedis-arrayish@0.2.1(transitive)
- Removedis-directory@0.3.1(transitive)
- Removedis-fullwidth-code-point@3.0.0(transitive)
- Removedis-interactive@1.0.0(transitive)
- Removedis-number@7.0.0(transitive)
- Removedis-stream@2.0.1(transitive)
- Removedis-unicode-supported@0.1.0(transitive)
- Removedis-wsl@1.1.0(transitive)
- Removedisarray@1.0.0(transitive)
- Removedisexe@2.0.0(transitive)
- Removedjest-get-type@29.6.3(transitive)
- Removedjest-util@27.5.1(transitive)
- Removedjest-validate@29.7.0(transitive)
- Removedjest-worker@27.5.1(transitive)
- Removedjs-tokens@4.0.0(transitive)
- Removedjs-yaml@3.14.1(transitive)
- Removedjsc-safe-url@0.2.4(transitive)
- Removedjsesc@3.0.2(transitive)
- Removedjson-parse-better-errors@1.0.2(transitive)
- Removedjson5@2.2.3(transitive)
- Removedleven@3.1.0(transitive)
- Removedlocate-path@6.0.0(transitive)
- Removedlodash.throttle@4.1.1(transitive)
- Removedlog-symbols@4.1.0(transitive)
- Removedloose-envify@1.4.0(transitive)
- Removedlru-cache@5.1.1(transitive)
- Removedmakeerror@1.0.12(transitive)
- Removedmerge-stream@2.0.0(transitive)
- Removedmetro@0.78.0(transitive)
- Removedmetro-babel-transformer@0.78.0(transitive)
- Removedmetro-cache@0.78.0(transitive)
- Removedmetro-cache-key@0.78.0(transitive)
- Removedmetro-config@0.78.0(transitive)
- Removedmetro-core@0.78.0(transitive)
- Removedmetro-file-map@0.78.0(transitive)
- Removedmetro-minify-terser@0.78.0(transitive)
- Removedmetro-resolver@0.78.0(transitive)
- Removedmetro-runtime@0.78.0(transitive)
- Removedmetro-source-map@0.78.0(transitive)
- Removedmetro-symbolicate@0.78.0(transitive)
- Removedmetro-transform-plugins@0.78.0(transitive)
- Removedmetro-transform-worker@0.78.0(transitive)
- Removedmicromatch@4.0.8(transitive)
- Removedmime@1.6.02.6.0(transitive)
- Removedmime-db@1.52.01.53.0(transitive)
- Removedmime-types@2.1.35(transitive)
- Removedmimic-fn@2.1.0(transitive)
- Removedminimatch@3.1.2(transitive)
- Removedms@2.0.02.1.3(transitive)
- Removednegotiator@0.6.3(transitive)
- Removednocache@3.0.4(transitive)
- Removednode-abort-controller@3.1.1(transitive)
- Removednode-fetch@2.7.0(transitive)
- Removednode-int64@0.4.0(transitive)
- Removednode-releases@2.0.18(transitive)
- Removednormalize-path@3.0.0(transitive)
- Removednpm-run-path@4.0.1(transitive)
- Removednullthrows@1.1.1(transitive)
- Removedob1@0.78.0(transitive)
- Removedon-finished@2.3.02.4.1(transitive)
- Removedon-headers@1.0.2(transitive)
- Removedonce@1.4.0(transitive)
- Removedonetime@5.1.2(transitive)
- Removedopen@6.4.0(transitive)
- Removedora@5.4.1(transitive)
- Removedp-limit@3.1.0(transitive)
- Removedp-locate@5.0.0(transitive)
- Removedparse-json@4.0.0(transitive)
- Removedparseurl@1.3.3(transitive)
- Removedpath-exists@4.0.0(transitive)
- Removedpath-is-absolute@1.0.1(transitive)
- Removedpath-key@3.1.1(transitive)
- Removedpicocolors@1.1.1(transitive)
- Removedpicomatch@2.3.1(transitive)
- Removedpretty-format@26.6.229.7.0(transitive)
- Removedprocess-nextick-args@2.0.1(transitive)
- Removedqueue@6.0.2(transitive)
- Removedrange-parser@1.2.1(transitive)
- Removedreact-is@17.0.218.3.1(transitive)
- Removedreact-refresh@0.4.3(transitive)
- Removedreadable-stream@2.3.83.6.2(transitive)
- Removedreadline@1.3.0(transitive)
- Removedregenerator-runtime@0.14.1(transitive)
- Removedrequire-directory@2.1.1(transitive)
- Removedresolve-from@3.0.0(transitive)
- Removedrestore-cursor@3.1.0(transitive)
- Removedrimraf@3.0.2(transitive)
- Removedsafe-buffer@5.1.25.2.1(transitive)
- Removedsemver@6.3.17.6.3(transitive)
- Removedsend@0.19.0(transitive)
- Removedserialize-error@2.1.0(transitive)
- Removedserve-static@1.16.2(transitive)
- Removedsetprototypeof@1.2.0(transitive)
- Removedshebang-command@2.0.0(transitive)
- Removedshebang-regex@3.0.0(transitive)
- Removedshell-quote@1.8.1(transitive)
- Removedsignal-exit@3.0.7(transitive)
- Removedsource-map@0.5.70.6.1(transitive)
- Removedsource-map-support@0.5.21(transitive)
- Removedsprintf-js@1.0.3(transitive)
- Removedstackframe@1.3.4(transitive)
- Removedstatuses@1.5.02.0.1(transitive)
- Removedstring-width@4.2.3(transitive)
- Removedstring_decoder@1.1.11.3.0(transitive)
- Removedstrip-ansi@6.0.1(transitive)
- Removedstrip-final-newline@2.0.0(transitive)
- Removedsupports-color@7.2.08.1.1(transitive)
- Removedterser@5.36.0(transitive)
- Removedthroat@5.0.0(transitive)
- Removedthrough2@2.0.5(transitive)
- Removedtmpl@1.0.5(transitive)
- Removedto-regex-range@5.0.1(transitive)
- Removedtoidentifier@1.0.1(transitive)
- Removedtr46@0.0.3(transitive)
- Removedundici-types@6.19.8(transitive)
- Removedunpipe@1.0.0(transitive)
- Removedupdate-browserslist-db@1.1.1(transitive)
- Removedutil-deprecate@1.0.2(transitive)
- Removedutils-merge@1.0.1(transitive)
- Removedvary@1.1.2(transitive)
- Removedvlq@1.0.1(transitive)
- Removedwalker@1.0.8(transitive)
- Removedwcwidth@1.0.1(transitive)
- Removedwebidl-conversions@3.0.1(transitive)
- Removedwhatwg-url@5.0.0(transitive)
- Removedwhich@2.0.2(transitive)
- Removedwrap-ansi@7.0.0(transitive)
- Removedwrappy@1.0.2(transitive)
- Removedws@7.5.10(transitive)
- Removedxtend@4.0.2(transitive)
- Removedy18n@5.0.8(transitive)
- Removedyallist@3.1.1(transitive)
- Removedyargs@17.7.2(transitive)
- Removedyargs-parser@21.1.1(transitive)
- Removedyocto-queue@0.1.0(transitive)