Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected token in components/Dialog.js #33

Closed
vault13tech opened this issue Mar 24, 2017 · 16 comments
Closed

Unexpected token in components/Dialog.js #33

vault13tech opened this issue Mar 24, 2017 · 16 comments

Comments

@vault13tech
Copy link

while I upgrade 0.5.20 -> 0.7.22
it shows the error below at runtime:
node_modules/react-native-popup-dialog/src/components/Dialog.js: Unexpected token, expected , (16:14)
seems the problem is at
import { type DialogType} from ...

run on:
react 15.4.2
react-native 0.41.2

any suggestion??

@joegoodall1
Copy link

Getting the same error ^^^^

@jacklam718
Copy link
Owner

@vault13tech @joegoodall1 I tried but I didn't get the error 🤔

@joegoodall1
Copy link

Problem seems to have resolved itself. Thanks for replying so quickly.

@vault13tech
Copy link
Author

interesting...
@jacklam718 I'll try to figure out what happened
@joegoodall1 is there any clue to be notice??

@jacklam718
Copy link
Owner

@vault13tech Thanks a lot

@joegoodall1
Copy link

This error seems to be back now when trying to build apk for release?

@joegoodall1
Copy link

joegoodall1 commented Apr 3, 2017

Just noticed in the packager that react-native-pop-up-dialog gets missed out?

:react-native-linear-gradient:transformNative_libsWithSyncJniLibsForRelease UP-TO-DATE
:react-native-linear-gradient:bundleRelease UP-TO-DATE
//react-native-pop-up-dialog should be included here
:react-native-sound:preBuild UP-TO-DATE
:react-native-sound:preReleaseBuild UP-TO-DATE

@jacklam718
Copy link
Owner

@vault13tech @joegoodall1 Can you try install this version 0.7.23 ? This version might be can solve the issue.

@vault13tech
Copy link
Author

at first, I tried to upgrade to 0.7.23 directly, it show some error message at runtime,
then I just uninstall and reinstall again, it works just fine! (how strange).

thank you @jacklam718 , excellent works 👍

@jacklam718
Copy link
Owner

@vault13tech Nice.

@vault13tech
Copy link
Author

vault13tech commented Apr 13, 2017

oh!! we got problems.
when I tried to build a app release, the error shown:

TransformError: \Projects\ProjectA\node_modules\react-native-popup-dialog\index.js:
Unknown plugin "babel-plugin-flow-react-proptypes" specified in "\Projects\ProjectA\node_modules\react-native-popup-dialog\.babelrc" at 0,
attempted to resolve relative to "\Projects\
ProjectA\node_modules\react-native-popup-dialog"

did I missing somthing??

@jacklam718 jacklam718 reopened this Apr 13, 2017
@jacklam718
Copy link
Owner

@vault13tech So sorry. I will fix it.

@vault13tech
Copy link
Author

@jacklam718
I change .babelrc from
"plugins": ["babel-plugin-flow-react-proptypes"]
to
"env": { "development": { "plugins": ["babel-plugin-flow-react-proptypes"] } }

it will only work on development

@jacklam718
Copy link
Owner

jacklam718 commented Apr 13, 2017

@vault13tech Can you try install this version 0.7.26 thanks.

@vault13tech
Copy link
Author

@jacklam718 I accidentally install the version: 0.7.26 😄
and it seems works fine both on development & release build.
thanks again 😄

@jacklam718
Copy link
Owner

@vault13tech Nice. So sorry about that 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants