Skip to content

[0.57.0-rc.4] cli crashes when trying to run local development server #21054

Description

@michaelknoch

Environment

React Native Environment Info:
System:
OS: macOS High Sierra 10.13.6
CPU: x64 Intel(R) Core(TM) i5-6267U CPU @ 2.90GHz
Memory: 7.22 GB / 16.00 GB
Shell: 5.3 - /bin/zsh
Binaries:
Node: 8.11.3 - /usr/local/bin/node
npm: 6.1.0 - /usr/local/bin/npm
Watchman: 4.7.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 11.4, macOS 10.13, tvOS 11.4, watchOS 4.3
Android SDK:
Build Tools: 23.0.1, 23.0.2, 23.0.3, 25.0.1, 25.0.2, 25.0.3, 26.0.0, 26.0.1, 26.0.2, 27.0.0, 27.0.3
API Levels: 23, 24, 25, 26, 27
IDEs:
Android Studio: 3.1 AI-173.4819257
Xcode: 9.4.1/9F2000 - /usr/bin/xcodebuild
npmPackages:
react: ^16.4.1 => 16.4.1 react-native: 0.57.0-rc.4 npmGlobalPackages:
react-native-cli: 2.0.1
react-native-git-upgrade: 0.2.7
react-native: 0.56.0

Description

I tried to run my app with rn 0.57rc 4 but it seems that weird things are happening when transforming local-cli/server/server.js. I migrated from babel-preset-react-native to metro-react-native-babel-preset. The cli crashes when trying to start local development server.

>nodenode_modules/react-native/local-cli/cli.jsstart/Users/michaelknoch/dev/flow/smartphone-app/node_modules/@babel/core/lib/transformation/normalize-file.js:209throwerr;^
SyntaxError: .../node_modules/react-native/local-cli/server/server.js: Unexpectedtoken,expected ";" (9:32)
7|})8|);>9|/* remotedev-server end */codeislicensedundertheMITlicensefoundinthe|^10|*LICENSEfileintherootdirectoryofthissourcetree.11|*12|* @format

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions