question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unhandled JS Exception: Unexpected token Expected a ')' or a ' after a parameter declaration.

See original GitHub issue

Description

after delete file yarn.lock and yarn install then build app , that error occur error

Version

0.60.6

Output of npx react-native info

info Fetching system and libraries information… System: OS: macOS 11.6 CPU: (6) x64 Intel® Core™ i5-8500B CPU @ 3.00GHz Memory: 218.86 MB / 20.00 GB Shell: 5.8 - /bin/zsh Binaries: Node: 16.3.0 - /usr/local/bin/node Yarn: 1.22.17 - ~/Documents/RabilooWorkSpace/yakuodo_app_mobile/node_modules/.bin/yarn npm: 7.15.1 - /usr/local/bin/npm SDKs: iOS SDK: Platforms: DriverKit 21.2, iOS 15.2, macOS 12.1, tvOS 15.2, watchOS 8.3 IDEs: Android Studio: 4.2 AI-202.7660.26.42.7351085 Xcode: 13.2.1/13C100 - /usr/bin/xcodebuild npmPackages: react: 16.8.6 => 16.8.6 react-native: 0.60.6 => 0.60.6

Steps to reproduce

step 1: delete file yarn.lock and Podfile.lock step 2: run ‘yarn install’ step 3: run ‘cd ios and Pod install’ step 4: build app after show splash screen , app show error

error

Snack, code example, screenshot, or link to a repository

No response

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:10
  • Comments:28 (2 by maintainers)

github_iconTop GitHub Comments

9reactions
joshua-davis-rosecommented, Jan 12, 2022

I finally got it to work by setting explicit versions in my devDependencies and resolutions. I also needed to delete my node_modules and yarn.lock, but YMMV. I went back to 7.16.5 since it was the upgrade to 7.16.7 that I first saw the issue, but the latter may be safe.

"devDependencies": {
    "@babel/core": "7.16.5",
    "@babel/preset-flow": "7.16.5",
    "@babel/runtime": "7.16.5"
}
"resolutions": {
    "@babel/traverse": "7.16.5"
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

SyntaxError: Unexpected token '='. Expected a ')' or a ',' after a ...
Safari was throwing this error with no line number or stack trace, and it's a fatal error so it was killing the rest...
Read more >
unhandled js exception: unexpected token ':'. expected a ')' or ...
unhandled js exception : unexpected token ':'. expected a ')' or a ',' after a parameter declaration. The solution is more tricky.
Read more >
How To Solve React Native: Unexpected token ':'.
How To Solve React Native: Unexpected token ':'. Expected a ')' or a ',' after a parameter declaration.
Read more >
SyntaxError: Unexpected token - JavaScript - MDN Web Docs
The JavaScript exceptions "unexpected token" occur when a specific language construct was expected, but something else was provided.
Read more >
Unexpected token " + token + "; expected - Opster
Coordinating (client) node. There is some confusion in the use of coordinating node terminology. Client nodes were removed from Elasticsearch after version 2.4 ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found