Getting trouble with npm run start.android in angular2seed - android

I am using angular2seed-advanced Check here. And i follow the steps mantioned in that. while developing app i give npm start i got the http://localhost:5555/ and it correctly dispalyed on browser. after that when i give the command that which is for android
ie, npm run start.
android i got an error Unable to install dependencies. Make sure your package.json is valid and all dependencies are correct. Error is: The package #angular/core#2.1.0-beta.0 does not satisfy its siblings' peerDependencies requirements!. while running npm install command i got
UNMET PEER DEPENDENCY #angular/common#2.1.0-beta.0
+-- UNMET PEER DEPENDENCY #angular/compiler#2.1.0-beta.0
+-- UNMET PEER DEPENDENCY #angular/core#2.1.0-beta.0
+-- UNMET PEER DEPENDENCY #angular/http#2.1.0-beta.0
+-- UNMET PEER DEPENDENCY #angular/platform-browser#2.1.0-beta.0
what should i do? anyone please provide solution for this. here i attached my package.json file
package.json
"devDependencies": {
"#angular/compiler-cli": "^0.6.1",
"#angular/platform-server": "^2.0.0",
"#angular/tsc-wrapped": "^0.3.0",
"#types/async": "^2.0.31",
"#types/browser-sync": "^0.0.32",
"#types/connect-livereload": "^0.5.29",
"#types/core-js": "^0.9.32",
"#types/express": "^4.0.32",
"#types/gulp": "^3.8.31",
"#types/gulp-load-plugins": "^0.0.27",
"#types/gulp-protractor": "^1.0.28",
"#types/gulp-sass": "^0.0.28",
"#types/gulp-shell": "^0.0.28",
"#types/gulp-util": "^3.0.28",
"#types/jasmine": "^2.2.33",
"#types/lodash": "^4.14.36",
"#types/node": "^6.0.38",
"#types/protractor": "^1.5.18",
"#types/rimraf": "^0.0.27",
"#types/run-sequence": "^0.0.27",
"#types/selenium-webdriver": "2.44.*",
"#types/systemjs": "^0.19.30",
"#types/yargs": "^0.0.30",
"#types/zone.js": "^0.0.26",
"async": "^2.0.1",
"autoprefixer": "^6.3.7",
"browser-sync": "^2.13.0",
"codelyzer": "1.0.0-beta.0",
"colorguard": "^1.2.0",
"compression": "^1.6.2",
"connect": "^3.4.1",
"connect-history-api-fallback": "^1.3.0",
"connect-livereload": "^0.5.4",
"cssnano": "^3.7.3",
"deep-extend": "^0.4.1",
"doiuse": "^2.4.1",
"electron-connect": "^0.4.2",
"electron-debug": "^1.0.0",
"electron-prebuilt": "^1.2.1",
"event-stream": "^3.3.3",
"express": "~4.14.0",
"express-history-api-fallback": "^2.0.0",
"extend": "^3.0.0",
"gulp": "^3.9.1",
"gulp-atom-electron": "^1.6.1",
"gulp-cached": "^1.1.0",
"gulp-clean-css": "^2.0.11",
"gulp-concat": "^2.6.0",
"gulp-concat-css": "^2.3.0",
"gulp-filter": "^4.0.0",
"gulp-inject": "^4.1.0",
"gulp-inline-ng2-template": "^3.0.1",
"gulp-load-plugins": "^1.2.4",
"gulp-newer": "^1.2.0",
"gulp-plumber": "~1.1.0",
"gulp-postcss": "^6.1.1",
"gulp-progeny": "^0.3.1",
"gulp-protractor": "^2.4.0",
"gulp-replace": "^0.5.4",
"gulp-sass": "^2.3.2",
"gulp-sass-lint": "^1.2.0",
"gulp-sourcemaps": "2.0.0-alpha",
"gulp-symdest": "^1.0.0",
"gulp-template": "^4.0.0",
"gulp-tslint": "^6.0.1",
"gulp-typedoc": "^2.0.0",
"gulp-typescript": "^3.0.1",
"gulp-uglify": "^2.0.0",
"gulp-util": "^3.0.7",
"gulp-watch": "^4.3.8",
"is-ci": "^1.0.9",
"isstream": "^0.1.2",
"jasmine-core": "~2.4.1",
"jasmine-spec-reporter": "^2.5.0",
"karma": "~0.13.22",
"karma-chrome-launcher": "~1.0.1",
"karma-coverage": "^1.1.0",
"karma-jasmine": "~1.0.2",
"karma-mocha-reporter": "^2.0.4",
"merge-stream": "^1.0.0",
"open": "0.0.5",
"postcss-reporter": "^1.4.1",
"protractor": "^3.3.0",
"remap-istanbul": "^0.6.4",
"rimraf": "^2.5.3",
"run-sequence": "^1.2.2",
"semver": "^5.3.0",
"serve-static": "^1.11.1",
"slash": "~1.0.0",
"stylelint": "^7.0.2",
"stylelint-config-standard": "^11.0.0",
"systemjs-builder": "0.15.31",
"tildify": "^1.2.0",
"traceur": "^0.0.111",
"ts-node": "^1.0.0",
"tslint": "^3.13.0",
"tslint-stylish": "2.1.0-beta",
"typedoc": "^0.4.5",
"typescript": "2.0.2",
"walk": "^2.3.9",
"yargs": "^4.8.0"
},
"dependencies": {
"#angular/common": "^2.1.0-beta.0",
"#angular/compiler": "^2.1.0-beta.0",
"#angular/core": "^2.1.0-beta.0",
"#angular/forms": "^2.1.0-beta.0",
"#angular/http": "^2.1.0-beta.0",
"#angular/platform-browser": "^2.1.0-beta.0",
"#angular/platform-browser-dynamic": "^2.1.0-beta.0",
"#angular/router": "^3.1.0-beta.0",
"#ngrx/core": "^1.2.0",
"#ngrx/effects": "^2.0.0",
"#ngrx/store": "^2.2.1",
"angulartics2": "^1.1.5",
"core-js": "^2.4.1",
"es-module-loader": "^1.0.0",
"lodash": "^4.15.0",
"ng2-translate": "^2.4.4",
"reflect-metadata": "^0.1.8",
"rxjs": "5.0.0-beta.12",
"systemjs": "0.19.38",
"zone.js": "0.6.23"
}
}
nativescript/package.json
"dependencies": {
"#angular/common": "^2.1.0-beta.0",
"#angular/compiler": "^2.1.0-beta.0",
"#angular/core": "^2.1.0-beta.0",
"#angular/forms": "^2.1.0-beta.0",
"#angular/http": "^2.1.0-beta.0",
"#angular/platform-browser": "^2.1.0-beta.0",
"#angular/platform-browser-dynamic": "^2.1.0-beta.0",
"#angular/platform-server": "^2.1.0-beta.0",
"#angular/router": "^3.1.0-beta.0",
"#ngrx/core": "^1.2.0",
"#ngrx/effects": "^2.0.0",
"#ngrx/store": "^2.2.1",
"angulartics2": "^1.1.6",
"es6-promise": "^3.0.2",
"es6-shim": "^0.35.0",
"lodash": "^4.15.0",
"nativescript-angular": "next",
"nativescript-ng2-translate": "^1.2.0",
"nativescript-theme-core": "0.0.10",
"ng2-translate": "^2.4.4",
"parse5": "1.4.2",
"punycode": "1.3.2",
"querystring": "0.2.0",
"reflect-metadata": "^0.1.8",
"rxjs": "5.0.0-beta.12",
"tns-core-modules": "^2.3.0",
"url": "0.10.3"
},
"devDependencies": {
"zone.js": "^0.6.21",
"babel-traverse": "6.12.0",
"babel-types": "6.11.1",
"babylon": "6.8.4",
"filewalker": "0.1.2",
"lazy": "1.0.11",
"nativescript-dev-typescript": "^0.3.2",
"shelljs": "^0.7.0",
"typescript": "^1.8.10"
}

Not in this version of angular-seed. But in previous versions I had same problems.
Fix was install zone.js and rxjs first.
removing node_modules from root and nativescript folder
install zone.js and rxjs
tns install
something like this. Maybe installing order was off.
It maybe other dependency than zone.js and rxjs.
you can try npm -i #angular/common#2.1.0-beta.0 to see which dependencies are unmet
Hope this helps
UPDATE 1
After I tried cd nativescript && npm i command gave me following error.
npm WARN ng2-translate#2.5.0 requires a peer of #angular/core#~2.0.0 but none was installed.
npm WARN ng2-translate#2.5.0 requires a peer of #angular/http#~2.0.0 but none was installed.
npm WARN #ngrx/store#2.2.1 requires a peer of #angular/core#^2.0.0 but none was installed.
npm WARN #ngrx/effects#2.0.0 requires a peer of #angular/core#^2.0.0 but none was installed.
this means version 2.5.0 of plugin ng2-translate requires version ~2.0.0 of #angular/core. But version ~2.0.0 of #angular/core is not installed.
So downgrading few beta version in nativescript/package.json file fixed the problem run on my machine.
"#angular/common": "^2.0.0",
"#angular/compiler": "^2.0.0",
"#angular/core": "^2.0.0",
"#angular/forms": "^2.0.0",
"#angular/http": "^2.0.0",
"#angular/platform-browser": "^2.0.0",
"#angular/platform-browser-dynamic": "^2.0.0",
"#angular/platform-server": "^2.0.0",
"#angular/router": "^3.0.0",
I advice to ask developers directly on github or slack channel, or use stable release of that repo. Cheers.

Related

react-native-webview android issue: Found interface com.facebook.react.uimanager.events.EventDispatcher, but class was expected

I am using react-native-webview for my react native app which has the rn version 0.64.4,
But I cannot open screen when we have a web view in it, the app get crash immediately. this is only happening on the android. Then I open up the android project via android studio, then I could see the below error on the log. How can I fix this issue?
Error log:
E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.xapp, PID: 21712
java.lang.IncompatibleClassChangeError: Found interface com.facebook.react.uimanager.events.EventDispatcher, but class was expected (declaration of 'com.facebook.react.uimanager.events.EventDispatcher' appears in /data/app/~~qPom7HPfdYNLFEMUio836A==/com.verime-gQSY9JQLtB6GGgsqfvIrFg==/base.apk!classes3.dex)
at com.reactnativecommunity.webview.RNCWebViewManager.dispatchEvent(RNCWebViewManager.java:168)
at com.reactnativecommunity.webview.RNCWebViewManager$RNCWebChromeClient.onProgressChanged(RNCWebViewManager.java:1153)
at la.handleMessage(chromium-TrichromeWebViewGoogle6432.aab-stable-530410534:278)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:226)
at android.os.Looper.loop(Looper.java:313)
at android.app.ActivityThread.main(ActivityThread.java:8751)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:571)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1135)
This is my package.json
{
"name": "xapp",
"version": "0.0.1",
"private": true,
"scripts": {
"android": "react-native run-android",
"ios": "react-native run-ios",
"start": "react-native start",
"test": "jest",
"lint": "eslint .",
"np": "np --no-publish",
"postversion": "react-native-version",
"build:ios": "react-native bundle --entry-file index.js --platform ios --dev false --bundle-output ios/main.jsbundle --assets-dest ios",
"postinstall": "patch-package"
},
"dependencies": {
"#react-native-async-storage/async-storage": "^1.17.10",
"#react-native-community/art": "^1.2.0",
"#react-native-community/checkbox": "^0.5.7",
"#react-native-community/datetimepicker": "^3.4.1",
"#react-native-community/picker": "^1.8.1",
"#react-native-firebase/app": "^11.0.0",
"#react-native-firebase/messaging": "^11.0.0",
"#react-native-picker/picker": "^2.4.8",
"#react-navigation/bottom-tabs": "^5.5.2",
"#react-navigation/native": "^5.6.1",
"#react-navigation/stack": "^5.5.1",
"#woonivers/react-native-document-scanner": "^2.1.1",
"axios": "^0.21.1",
"base-64": "^0.1.0",
"install": "^0.13.0",
"lottie-react-native": "^5.1.4",
"moment": "^2.27.0",
"native-base": "^2.15.2",
"npm": "^7.20.5",
"pdf-lib": "^1.10.0",
"radio-buttons-react-native": "^1.0.4",
"react": "17.0.1",
"react-native": "0.64.4",
"react-native-biometrics": "^3.0.1",
"react-native-blob-util": "^0.15.0",
"react-native-camera": "^3.30.0",
"react-native-circular-progress": "^1.3.7",
"react-native-contacts": "^7.0.2",
"react-native-device-info": "^8.0.1",
"react-native-document-picker": "^5.0.3",
"react-native-floating-action": "^1.21.0",
"react-native-fs": "^2.16.6",
"react-native-gesture-handler": "^1.10.3",
"react-native-image-crop-picker": "^0.36.2",
"react-native-image-picker": "^3.3.2",
"react-native-image-progress": "^1.1.1",
"react-native-image-resizer": "^1.2.6",
"react-native-image-to-pdf": "^1.2.0",
"react-native-image-tools-wm": "^1.5.8",
"react-native-invoke-app": "^1.0.6",
"react-native-jitsi-meet": "^2.2.0",
"react-native-keyboard-aware-scroll-view": "^0.9.5",
"react-native-keychain": "^7.0.0",
"react-native-linear-gradient": "^2.6.2",
"react-native-masked-text": "^1.13.0",
"react-native-modal-datetime-picker": "^9.2.0",
"react-native-paper": "^3.10.1",
"react-native-pdf": "^6.2.0",
"react-native-pdf-lib": "^1.0.0",
"react-native-permissions": "^3.0.5",
"react-native-perspective-image-cropper": "git+https://github.com/kmwi/react-native-perspective-image-cropper.git",
"react-native-progress": "^4.1.2",
"react-native-reanimated": "^1.9.0",
"react-native-rectangle-scanner": "^1.0.10",
"react-native-safe-area-context": "^3.0.5",
"react-native-screens": "^2.9.0",
"react-native-select-multiple": "^2.1.0",
"react-native-signature-canvas": "4.4.1",
"react-native-simple-radio-button": "^2.7.4",
"react-native-simple-toast": "^1.1.2",
"react-native-snackbar": "^2.4.0",
"react-native-snap-carousel": "^3.9.1",
"react-native-status-bar-height": "^2.6.0",
"react-native-svg": "git+https://github.com/expo/react-native-svg.git",
"react-native-tooltips": "^1.0.3",
"react-native-user-avatar": "^1.0.8",
"react-native-vector-icons": "^7.0.0",
"react-native-view-pdf": "^0.11.0",
"react-native-virtual-keyboard": "^1.1.0",
"react-native-walkthrough-tooltip": "^1.3.1",
"react-native-webview": "11.18.1",
"react-navigation": "^4.3.9",
"react-navigation-drawer": "^2.4.13",
"react-navigation-stack": "^2.7.0",
"react-redux": "^7.2.0",
"redux": "^4.0.5",
"redux-devtools-extension": "^2.13.8",
"redux-persist": "^6.0.0",
"redux-saga": "^1.1.3"
},
"devDependencies": {
"#babel/core": "^7.12.9",
"#babel/runtime": "^7.12.5",
"#react-native-community/eslint-config": "^2.0.0",
"babel-jest": "^26.6.3",
"eslint": "7.14.0",
"jest": "^26.6.3",
"jetifier": "^2.0.0",
"metro-react-native-babel-preset": "^0.64.0",
"np": "^7.6.1",
"patch-package": "^6.5.0",
"postinstall-postinstall": "^2.1.0",
"react-native-version": "^4.0.0",
"react-test-renderer": "17.0.1",
"reactotron-react-native": "^5.0.0",
"reactotron-redux": "^3.1.3",
"reactotron-redux-saga": "^4.2.3"
},
"jest": {
"preset": "react-native"
}
}
Similar case here, the libraries involved are invertase/react-native-apple-authentication and react-native-webview. They suddenly started crashing due to a Kotlin version difference, after correcting them, react-native-reanimated started giving a similar error as yours, but instead of expecting a class, it expects interface, the other way around.
Found class com.facebook.react.uimanager.events.EventDispatcher, but interface was expected.
at com.swmansion.reanimated.NodesManager.(NodesManager.java:116)
UPDATE: I just resolved my problem, it was due to a library trying to use a newer version of react native, and I ended upgrading my project to RN 64.
Since RN 64, the EventDispatcher.java file in the react-native project changed a lot, from class in 63.5 to a interface in 64. Your issue could be that a library is trying to use older RN version and is expecting a class, but your RN version already works with Interface regarding that file.
Hope it helps you, good luck!

NativeScript - When I am trying to take a build in Android I am getting an Error as below but I can able to take build in IOS

NativeScript - When I am trying to take a build in Android I am getting an Error as below but I can able to take build in IOS.
ERROR in ../node_modules/nativescript-permissions/permissions.js
Module not found: Error: Can't resolve '#master.technology/permissions' in
'/node_modules/nativescript-permissions'
# ../node_modules/nativescript-permissions/permissions.js 13:17-58
# ../node_modules/nativescript-camera/camera.js
# ./app/virtualevent/virtualevent.component.ts
# ./app/app.module.tns.ts
# ./main.tns.ts
Webpack compilation complete.
Executing webpack failed with exit code 2.
The above is the error we are getting when trying to take the Android Build
Environment:
OS: macOS 12.3
CPU: (10) arm64 Apple M1 Pro
Shell: /bin/zsh
node: 14.18.2
npm: 6.14.15
nativescript: 8.1.5
android
java: 17.0.2
ndk: Not Found
apis: Not Found
build_tools: Not Found
system_images: Not Found
ios
xcode: 13.3/13E113
cocoapods: 1.11.2
python: Not Found
python3: 3.8.9
ruby: 2.7.5
platforms:
DriverKit 21.4
iOS 15.4
macOS 12.3
tvOS 15.4
watchOS 8.5
Dependencies:
"dependencies": {
"#angular/animations": "^12.2.5",
"#angular/common": "^12.2.5",
"#angular/compiler": "^12.2.5",
"#angular/core": "^12.2.5",
"#angular/forms": "^12.2.5",
"#angular/http": "~8.0.0-beta.10",
"#angular/platform-browser": "^12.2.5",
"#angular/platform-browser-dynamic": "^12.2.5",
"#angular/router": "^12.2.5",
"#nativescript/theme": "~2.2.1",
"#nstudio/nativescript-checkbox": "^1.0.0",
"base-64": "^1.0.0",
"core-js": "^2.6.9",
"material-ui-search-bar": "^0.4.2",
"nativescript-accordion": "^6.0.0-beta.2",
"nativescript-app-tour-updated": "^2.0.2",
"nativescript-camera": "^4.5.0",
"nativescript-collectionview": "^2.0.36",
"nativescript-danem-drop-down": "^1.0.3",
"nativescript-datetimepicker": "^1.2.2",
"nativescript-email": "^1.6.0",
"nativescript-google-places-autocomplete": "^1.0.3",
"nativescript-imagecropper": "^4.0.0",
"nativescript-imagepicker": "^7.1.0",
"nativescript-iqkeyboardmanager": "^1.5.1",
"nativescript-oauth": "^2.1.8",
"nativescript-oauth2": "^2.4.0",
"nativescript-permissions": "^1.3.9",
"nativescript-plugin-firebase": "^10.5.2",
"nativescript-slides": "^2.3.0",
"nativescript-ui-autocomplete": "^6.0.1",
"nativescript-ui-sidedrawer": "^8.0.1",
"nativescript-websockets": "^1.5.6",
"pusher-nativescript": "^1.0.0",
"reflect-metadata": "~0.1.12",
"rxjs": "~7.3.0",
"rxjs-compat": "^6.5.5",
"tslib": "1.10.0",
"zone.js": "~0.11.4",
"#nativescript/core": "~8.1.1",
"#nativescript/angular": "^12.2.0"
},
"devDependencies": {
"#angular-devkit/build-angular": "^13.2.5",
"#angular/cli": "^12.2.5",
"#angular/compiler-cli": "^12.2.5",
"#nativescript/android": "~8.1.1",
"#nativescript/ios": "~8.1.0",
"#nativescript/schematics": "~1.0.0",
"#nativescript/tslint-rules": "~0.0.5",
"#nativescript/webpack": "~5.0.0",
"#ngtools/webpack": "^13.2.5",
"#types/jasmine": "~3.3.8",
"#types/jasminewd2": "~2.0.3",
"#types/node": "~8.9.4",
"codelyzer": "^5.0.0",
"jasmine-core": "~3.4.0",
"jasmine-spec-reporter": "~4.2.1",
"karma": "^5.2.3",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.1",
"karma-jasmine": "~2.0.1",
"karma-jasmine-html-reporter": "^1.4.0",
"protractor": "^7.0.0",
"sass": "~1.39.0",
"ts-node": "~7.0.0",
"tslint": "~5.15.0",
"typescript": "~4.3.5"
}

Ionic Android App stuck on white screen after upgrading to Angular 12. Error: goog.getLocale is not a function

I recently tried upgrading Angular 11 to 12 in my Ionic App. It all went well, and the app is running with no errors in the browser.
However, when I tried to run it on an Android phone, after the splash-screen disappears, the app gets stuck in a white screen.
I tried using chrone://inspect tool and see if I get any errors and this showed up:
I also get the same error on the Android Logcat: E/Capacitor/Console: File: http://localhost/vendor-es2015.js - Line 15729 - Msg: ERROR TypeError: goog.getLocale is not a function
I tried adding timeout to the splash-screen, updating libraries, deleting node_modules and reinstalling them, but nothing worked. I can't find much info on the web about this error.
Can anyone tell me what this error means or why is the app stuck here? It works well if I go back to Angular 11.
My package.json looks like this:
"dependencies": {
"#agm/core": "^3.0.0-beta.0",
"#angular/common": "~12.2.3",
"#angular/core": "~12.2.3",
"#angular/forms": "~12.2.3",
"#angular/platform-browser": "~12.2.3",
"#angular/platform-browser-dynamic": "~12.2.3",
"#angular/router": "~12.2.3",
"#capacitor-community/background-geolocation": "^0.3.11",
"#capacitor/android": "^2.4.6",
"#capacitor/core": "^2.4.6",
"#capacitor/ios": "^2.4.6",
"#ionic-native/android-permissions": "^5.30.0",
"#ionic-native/clipboard": "^5.31.1",
"#ionic-native/core": "^5.30.0",
"#ionic-native/device": "^5.31.1",
"#ionic-native/diagnostic": "^5.32.1",
"#ionic-native/insomnia": "^5.30.0",
"#ionic-native/launch-navigator": "^5.30.0",
"#ionic-native/location-accuracy": "^5.30.0",
"#ionic-native/market": "^5.33.1",
"#ionic-native/mobile-accessibility": "^5.36.0",
"#ionic-native/splash-screen": "^5.30.0",
"#ionic-native/status-bar": "^5.30.0",
"#ionic/angular": "^5.6.14",
"#ionic/pwa-elements": "^3.0.2",
"#ngrx/effects": "^10.0.0",
"#ngrx/entity": "^10.0.0",
"#ngrx/schematics": "^10.0.0",
"#ngrx/store": "^10.0.0",
"#ngrx/store-devtools": "^10.0.0",
"#ngx-translate/core": "^12.1.2",
"#ngx-translate/http-loader": "^6.0.0",
"agm-direction": "^0.8.9",
"cordova-clipboard": "^1.3.0",
"cordova-plugin-actionsheet": "^2.3.3",
"cordova-plugin-android-permissions": "^1.1.2",
"cordova-plugin-device": "^2.0.3",
"cordova-plugin-dialogs": "^2.0.2",
"cordova-plugin-insomnia": "^4.3.0",
"cordova-plugin-market": "^1.2.0",
"cordova-plugin-network-information": "git+https://github.com/apache/cordova-plugin-network-information.git",
"cordova-plugin-request-location-accuracy": "^2.3.0",
"cordova.plugins.diagnostic": "^6.0.3",
"core-js": "^3.8.3",
"moment": "^2.28.0",
"ngx-signaturepad": "^0.0.9",
"phonegap-plugin-mobile-accessibility": "^1.0.5",
"rxjs": "^6.6.3",
"tslib": "^2.0.1",
"uk.co.workingedge.phonegap.plugin.launchnavigator": "^5.0.5",
"zone.js": "~0.11.4"
},
"devDependencies": {
"#angular-devkit/build-angular": "~12.2.3",
"#angular/cli": "^12.2.3",
"#angular/compiler": "~12.2.3",
"#angular/compiler-cli": "~12.2.3",
"#angular/language-service": "~12.2.3",
"#babel/core": "^7.10.2",
"#capacitor/cli": "2.4.6",
"#ionic/angular-toolkit": "^4.0.0",
"#storybook/addon-actions": "^5.3.19",
"#storybook/addon-knobs": "^5.3.19",
"#storybook/addon-links": "^5.3.19",
"#storybook/addon-notes": "^5.3.19",
"#storybook/addon-options": "^5.3.19",
"#storybook/addons": "^5.3.19",
"#storybook/angular": "^5.3.19",
"#types/googlemaps": "3.39.12",
"#types/jasmine": "~3.3.8",
"#types/jasminewd2": "~2.0.3",
"#types/node": "^12.11.1",
"agm-overlays": "^2.0.0",
"babel-loader": "^8.1.0",
"codelyzer": "^6.0.1",
"jasmine-core": "~3.4.0",
"jasmine-spec-reporter": "~4.2.1",
"karma": "^6.3.4",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.1",
"karma-jasmine": "~2.0.1",
"karma-jasmine-html-reporter": "^1.4.0",
"protractor": "^7.0.0",
"ts-node": "~7.0.0",
"tslint": "~6.1.0",
"typescript": "4.3.5"
},
Thank-you!
#edit 09/2021
as a temporary fix avoid to call the getGlobalLocale().
Add this to your index.html
<script>
var ngI18nClosureMode = false;
</script>
same here updating from angular#12.1 to #12.2.
meanwhile try to update to ^12.1

why ttcIndex and fontvariantSetting not found in cordova build?

"dependencies": {
"#angular/animations": "5.2.11",
"#angular/common": "5.2.9",
"#angular/compiler": "5.2.9",
"#angular/compiler-cli": "5.2.9",
"#angular/core": "5.2.9",
"#angular/forms": "5.2.9",
"#angular/http": "5.2.9",
"#angular/platform-browser": "5.2.9",
"#angular/platform-browser-dynamic": "5.2.9",
"#ionic-native/android-permissions": "^4.7.0",
"#ionic-native/app-availability": "^4.20.0",
"#ionic-native/base64": "^4.7.0",
"#ionic-native/camera": "^4.7.0",
"#ionic-native/contacts": "^4.9.1",
"#ionic-native/core": "4.6.0",
"#ionic-native/document-viewer": "^4.12.0",
"#ionic-native/file": "^4.7.0",
"#ionic-native/file-chooser": "^4.7.0",
"#ionic-native/file-opener": "^4.7.0",
"#ionic-native/file-path": "^4.7.0",
"#ionic-native/file-transfer": "^4.7.0",
"#ionic-native/firebase": "^4.7.0",
"#ionic-native/firebase-analytics": "^5.2.0",
"#ionic-native/http": "^4.12.2",
"#ionic-native/in-app-browser": "^4.7.0",
"#ionic-native/keyboard": "^4.12.0",
"#ionic-native/network": "^4.7.0",
"#ionic-native/sim": "^4.20.0",
"#ionic-native/social-sharing": "^4.7.0",
"#ionic-native/splash-screen": "4.6.0",
"#ionic-native/status-bar": "^4.6.0",
"#ionic-native/transfer": "^3.14.0",
"#ionic-native/unique-device-id": "^4.11.0",
"#ionic-native/video-player": "^4.9.0",
"#ionic/pro": "1.0.20",
"#ionic/storage": "2.1.3",
"angular-2-local-storage": "^2.0.0",
"chart.js": "^2.7.2",
"com-badrit-base64": "^0.2.0",
"com.lampa.startapp": "^6.1.6",
"cordova-android": "7.1.4",
"cordova-browser": "^5.0.4",
"cordova-ios": "4.5.5",
"cordova-play-services-version-adapter": "^1.0.2",
"cordova-plugin-advanced-http": "^2.0.6",
"cordova-plugin-analytics": "^2.0.0",
"cordova-plugin-android-permissions": "^1.0.0",
"cordova-plugin-appavailability": "0.4.2",
"cordova-plugin-camera": "^4.0.3",
"cordova-plugin-contacts": "^3.0.1",
"cordova-plugin-device": "^2.0.2",
"cordova-plugin-document-viewer": "^0.9.10",
"cordova-plugin-file": "^6.0.1",
"cordova-plugin-file-opener2": "^2.2.0",
"cordova-plugin-file-transfer": "^1.7.1",
"cordova-plugin-filechooser": "^1.2.0",
"cordova-plugin-filepath": "^1.5.1",
"cordova-plugin-firebase": "git+https://github.com/dpa99c/cordova-plugin-firebase.git#GH-1057-April-05-android-build-issue",
"cordova-plugin-firebase-analytics": "^1.0.1",
"cordova-plugin-inappbrowser": "^3.0.0",
"cordova-plugin-ionic-keyboard": "^2.1.3",
"cordova-plugin-ionic-webview": "^2.4.0",
"cordova-plugin-network-information": "^2.0.1",
"cordova-plugin-sim": "1.3.3",
"cordova-plugin-splashscreen": "^5.0.2",
"cordova-plugin-statusbar": "^2.4.2",
"cordova-plugin-uniquedeviceid": "^1.3.2",
"cordova-plugin-video-player": "^1.0.1",
"cordova-plugin-whitelist": "^1.3.3",
"cordova-plugin-x-socialsharing": "^5.4.4",
"crypto-js": "^3.1.9-1",
"es6-promise-plugin": "^4.2.2",
"ionic-angular": "3.9.2",
"ionic-plugin-keyboard": "^2.2.1",
"ionic-select-searchable": "^2.3.0",
"ionicons": "3.0.0",
"jquery": "^3.3.1",
"ngx-soap": "^0.2.2-beta6",
"node-sass": "^4.11.0",
"rxjs": "5.5.8",
"sw-toolbox": "3.6.0",
"xml2js": "^0.4.19",
"zone.js": "0.8.20"
},
Issue not solve by adding configure strategy or the plugin for support android.
AAPT: error: resource android:attr/fontVariationSettings not found.
AAPT: error: resource android:attr/ttcIndex not found.
in values.xml file.
and failed linking references. issue
Support library plugin tried,
configuration strategy
This is because on June 17, Google Updated Play Services and Firebase SDK requirements, a quick fix is edit project.properties on platforms/android folder and modify any lines that matches:
com.google.android.gms:play-services-*
and change the version to 11.8.0 to make it work.
Example:
cordova.system.library.5=com.google.android.gms:play-services-auth:+
Change to:
cordova.system.library.5=com.google.android.gms:play-services-auth:11.8.0
And build again.
To make it work this way you should use cordova-android 7 or 8.
Another fix is upgrade the compileSdkVersion to 28.

React Native: Android build - App.js: Cannot read property 'bindings' of null

I'm trying to build my project, but it has tuned into a nightmare...
Now I'm facing this issue when I run ./gradlew assembleRelease
org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':app:bundleReleaseJsAndAssets'.
And more specifically:
transform[stderr]: Trace: The node type SpreadProperty has been renamed to SpreadElement
transform[stderr]: at Object.isSpreadProperty (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/types/lib/validators/generated/index.js:4208:11)
transform[stderr]: at hasSpread (/Users/danielrvt/IdeaProjects/my-app/node_modules/babel-plugin-transform-object-rest-spread/lib/index.js:38:13)
transform[stderr]: at PluginPass.ObjectExpression (/Users/danielrvt/IdeaProjects/my-app/node_modules/babel-plugin-transform-object-rest-spread/lib/index.js:234:14)
transform[stderr]: at newFn (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/visitors.js:193:21)
transform[stderr]: at NodePath._call (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/path/context.js:53:20)
transform[stderr]: at NodePath.call (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/path/context.js:40:17)
transform[stderr]: at NodePath.visit (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/path/context.js:88:12)
transform[stderr]: at TraversalContext.visitQueue (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/context.js:118:16)
transform[stderr]: at TraversalContext.visitSingle (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/context.js:90:19)
transform[stderr]: at TraversalContext.visit (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/context.js:146:19)
App.js: Cannot read property 'bindings' of null
TypeError: Cannot read property 'bindings' of null
at Scope.moveBindingTo (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/scope/index.js:867:13)
at BlockScoping.updateScopeInfo (/Users/danielrvt/IdeaProjects/my-app/node_modules/babel-plugin-transform-es2015-block-scoping/lib/index.js:364:17)
at BlockScoping.run (/Users/danielrvt/IdeaProjects/my-app/node_modules/babel-plugin-transform-es2015-block-scoping/lib/index.js:330:12)
at PluginPass.BlockStatementSwitchStatementProgram (/Users/danielrvt/IdeaProjects/my-app/node_modules/babel-plugin-transform-es2015-block-scoping/lib/index.js:70:24)
at newFn (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/visitors.js:193:21)
at NodePath._call (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/path/context.js:53:20)
at NodePath.call (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/path/context.js:40:17)
at NodePath.visit (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/path/context.js:88:12)
at TraversalContext.visitQueue (/Users/danielrvt/IdeaProjects/my-app/node_modules/#babel/traverse/lib/context.js:118:16)
I honestly have absolutely no idea what's wrong now, how can I debug this?
This is my package.json:
{
"name": "my-app",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"dependencies": {
"#ptomasroos/react-native-multi-slider": "0.0.12",
"firebase": "^5.1.0",
"javascript-time-ago": "^1.0.30",
"mobx": "^4.1.1",
"mobx-react": "^5.0.0",
"native-base": "^2.8.1",
"prop-types": "^15.6.2",
"protobufjs": "^6.8.8",
"react": "16.2.0",
"react-native": "^0.57.7",
"react-native-actionsheet": "^2.3.0",
"react-native-aws3": "0.0.8",
"react-native-axios": "^0.17.1",
"react-native-billing": "^2.9.1",
"react-native-card-stack-swiper": "^1.0.5",
"react-native-collapsible": "^0.10.0",
"react-native-cookies": "^3.2.0",
"react-native-datepicker": "^1.6.0",
"react-native-dropdownalert": "^3.5.0",
"react-native-elements": "^0.19.0",
"react-native-event-listeners": "^1.0.3",
"react-native-expandable-section-flatlist": "^1.0.3",
"react-native-fbsdk": "^0.8.0",
"react-native-fcm": "^16.0.0",
"react-native-floating-action": "^1.10.1",
"react-native-geocoding": "^0.3.0",
"react-native-gifted-chat": "^0.4.3",
"react-native-google-places-autocomplete": "^1.3.6",
"react-native-hide-show-password-input": "^1.0.7",
"react-native-image-crop-picker": "^0.19.3",
"react-native-image-picker": "^0.26.10",
"react-native-image-placeholder": "^1.0.14",
"react-native-instagram-login": "^1.0.7",
"react-native-keyboard-aware-scroll-view": "^0.4.4",
"react-native-keyboard-aware-scrollview": "^2.0.0",
"react-native-keyboard-spacer": "^0.4.1",
"react-native-linear-gradient": "^2.4.0",
"react-native-linkedin": "^1.3.1",
"react-native-localization": "^2.0.0",
"react-native-material-bottom-navigation": "^0.9.0",
"react-native-modal-datetime-picker": "^6.0.0",
"react-native-open-settings": "^1.0.1",
"react-native-pages": "^0.7.0",
"react-native-permissions": "^1.1.1",
"react-native-picker-select": "^5.1.0",
"react-native-popup-menu": "^0.12.4",
"react-native-pulse": "^1.0.6",
"react-native-scrollable-tab-view": "^0.8.0",
"react-native-share": "^1.0.26",
"react-native-simple-toast": "0.0.8",
"react-native-snap-carousel": "^3.7.2",
"react-native-splash-screen": "^3.1.1",
"react-native-star-rating": "^1.0.9",
"react-native-swipe-cards": "^0.1.1",
"react-native-swipe-list-view": "^1.0.7",
"react-native-swipeable-flat-list": "0.0.5",
"react-native-swipeout": "^2.3.3",
"react-native-switch": "^1.4.0",
"react-native-twitter-signin": "https://github.com/GoldenOwlAsia/react-native-twitter-signin.git#master",
"react-native-view-more-text": "^2.0.1",
"react-native-viewpager": "^0.2.13",
"react-navigation": "^1.0.3",
"rn-viewpager": "^1.2.9"
},
"devDependencies": {
"#babel/plugin-proposal-decorators": "^7.2.0",
"babel-jest": "22.2.2",
"babel-preset-react-native": "4.0.0",
"jest": "22.2.2",
"react-test-renderer": "16.2.0"
},
"jest": {
"preset": "react-native",
"transform": {
"^.+\\.js$": "<rootDir>/node_modules/react-native/jest/preprocessor.js"
}
}
}
From https://www.npmjs.com/package/babel-preset-react-native
babel-preset-react-native has been replaced by
metro-react-native-babel-preset, which now uses Babel 7.0.0. If you're
using React Native v0.57 or later you should update your babel config
to point to the metro-react-native-babel-preset preset.
I think this may be related to a particular issue with babel-core, you could try this solution https://github.com/babel/babel/issues/8263#issuecomment-402546923
Add to your package.json
"babel-plugin-transform-object-rest-spread": "^7.0.0-beta.3"
and then npm install

Categories

Resources