| 2dd43328 | 24-Feb-2023 |
Evan Bacon <[email protected]> |
feat(cli)!: set node and babel env for CLI commands (#21337)
# Why
- User's may want to dynamically configure Metro or their Expo Config
file to work differently when bundling for production env
feat(cli)!: set node and babel env for CLI commands (#21337)
# Why
- User's may want to dynamically configure Metro or their Expo Config
file to work differently when bundling for production environments, they
can now do this by utilizing the standard `NODE_ENV` environment
variable. We've been doing this with Webpack since it was introduced.
<!--
Please describe the motivation for this PR, and link to relevant GitHub
issues, forums posts, or feature requests.
-->
# How
- Set `NODE_ENV` and `BABEL_ENV` environment variables to `development`
or `production` in `start`, `export`, `customize`, `install`, `run:ios`,
`run:android`, `config`, `prebuild` commands based on the input mode.
- This can be overwritten by setting `NODE_ENV` and `BABEL_ENV` manually
before running. `BABEL_ENV` will be set to `NODE_ENV` if defined.
- Most commands can safely default to assuming `development`.
- Only thing that this doesn't cover is `npx react-native bundle` and
`npx react-native start` (building from Xcode/Android Studio). We'll
need to change these commands in the future but it shouldn't be blocking
for this PR.
<!--
How did you build this feature or fix this bug and why?
-->
# Test Plan
<!--
Please describe how you tested this change and how a reviewer could
reproduce your test, especially if this PR does not include automated
tests! If possible, please also provide terminal output and/or
screenshots demonstrating your test/reproduction.
-->
# Checklist
<!--
Please check the appropriate items below if they apply to your diff.
This is required for changes to Expo modules.
-->
- [ ] Documentation is up to date to reflect these changes (eg:
https://docs.expo.dev and README.md).
- [ ] Conforms with the [Documentation Writing Style
Guide](https://github.com/expo/expo/blob/main/guides/Expo%20Documentation%20Writing%20Style%20Guide.md)
- [ ] This diff will work correctly for `expo prebuild` & EAS Build (eg:
updated a module plugin).
---------
Co-authored-by: Expo Bot <[email protected]>
show more ...
|
| 7a619cc1 | 09-Feb-2023 |
Evan Bacon <[email protected]> |
feat: support Hermes debugger on native when Metro web is running. (#21068)
# Why
Hermes debugger doesn't work when Metro web is enabled because the
endpoints are being intercepted by the histor
feat: support Hermes debugger on native when Metro web is running. (#21068)
# Why
Hermes debugger doesn't work when Metro web is enabled because the
endpoints are being intercepted by the history fallback middleware.
<!--
Please describe the motivation for this PR, and link to relevant GitHub
issues, forums posts, or feature requests.
-->
# How
- Detect inspector proxy requests and skip returning the index.html.
- Add better error handling for Apple script failing to launch Chrome
(which can sometimes happen when using chrome for web).
<!--
How did you build this feature or fix this bug and why?
-->
# Test Plan
- Added tests for endpoint logic
- `npx create-react-native-app -t with-router` `expo.jsEngine: hermes`
-> open ios -> press `j` -> doesn't fail.
<!--
Please describe how you tested this change and how a reviewer could
reproduce your test, especially if this PR does not include automated
tests! If possible, please also provide terminal output and/or
screenshots demonstrating your test/reproduction.
-->
# Checklist
<!--
Please check the appropriate items below if they apply to your diff.
This is required for changes to Expo modules.
-->
- [ ] Documentation is up to date to reflect these changes (eg:
https://docs.expo.dev and README.md).
- [ ] Conforms with the [Documentation Writing Style
Guide](https://github.com/expo/expo/blob/main/guides/Expo%20Documentation%20Writing%20Style%20Guide.md)
- [ ] This diff will work correctly for `expo prebuild` & EAS Build (eg:
updated a module plugin).
---------
Co-authored-by: Expo Bot <[email protected]>
show more ...
|
| b1f66971 | 17-Dec-2022 |
Linus Unnebäck <[email protected]> |
[@expo/cli] Avoid dependency on uuid (#20479)
# Why
Older versions of uuid is deprecated. This will start using a secure
random source, and will produce one less deprecation warning when
instal
[@expo/cli] Avoid dependency on uuid (#20479)
# Why
Older versions of uuid is deprecated. This will start using a secure
random source, and will produce one less deprecation warning when
installing!
> [email protected]: Please upgrade to version 7 or higher. Older versions may
use Math.random() in certain circumstances, which is known to be
problematic. See https://v8.dev/blog/math-random for details.
# How
The `@expo/cli` package only used the UUID v4 function from a Node.js
context, and Node.js already have a `randomUUID` function built in.
# Test Plan
I'm not sure, since this is used in the tests I'm hoping the CI will
cover it?
# Checklist
- [x] Documentation is up to date to reflect these changes (eg:
https://docs.expo.dev and README.md).
- [x] Conforms with the [Documentation Writing Style
Guide](https://github.com/expo/expo/blob/main/guides/Expo%20Documentation%20Writing%20Style%20Guide.md)
- [x] This diff will work correctly for `expo prebuild` & EAS Build (eg:
updated a module plugin).
Co-authored-by: Evan Bacon <[email protected]>
Co-authored-by: Evan Bacon <[email protected]>
show more ...
|