@pdj wrote:
Hello
I’m quite sure that code is not missing…
whenever comes to phonecall function…
it has error saying
TypeError: Object(…) is not a functionthe wierd one is that I used to use plugin well on import
import { CallNumber } from '@ionic-native/call-number
not with ngx postfix…
when I remove those ngx. it says can not find name CallNumber even I import it without ngx.import { CallNumber } from '@ionic-native/call-number/ngx'; constructor(public callNumber:CallNumber,public navCtrl: NavController, public navParams: NavParams) { } phonecall(){ this.callNumber.callNumber("15771234", true) .then(res => console.log('Launched dialer!', res)) .catch(err => console.log('Error launching dialer', err)); }
package.json is
{
“name”: “solami”,
“version”: “0.0.1”,
“author”: “Ionic Framework”,
“homepage”: “http://ionicframework.com/”,
“private”: true,
“scripts”: {
“start”: “ionic-app-scripts serve”,
“clean”: “ionic-app-scripts clean”,
“build”: “ionic-app-scripts build”,
“lint”: “ionic-app-scripts lint”
},
“dependencies”: {
“@angular/animations”: “5.2.11”,
“@angular/common”: “5.2.11”,
“@angular/compiler”: “5.2.11”,
“@angular/compiler-cli”: “5.2.11”,
“@angular/core”: “^5.2.11”,
“@angular/forms”: “5.2.11”,
“@angular/http”: “5.2.11”,
“@angular/platform-browser”: “5.2.11”,
“@angular/platform-browser-dynamic”: “5.2.11”,
“@angular/router”: “^7.2.9”,
“@ionic-native/call-number”: “^5.3.0”,
“@ionic-native/camera”: “^4.11.0”,
“@ionic-native/core”: “~4.10.0”,
“@ionic-native/document-viewer”: “^4.11.0”,
“@ionic-native/file”: “^4.11.0”,
“@ionic-native/file-transfer”: “^4.11.0”,
“@ionic-native/in-app-browser”: “^4.20.0”,
“@ionic-native/onesignal”: “^4.11.0”,
“@ionic-native/photo-viewer”: “^4.11.0”,
“@ionic-native/splash-screen”: “~4.10.0”,
“@ionic-native/sqlite”: “^4.11.0”,
“@ionic-native/status-bar”: “~4.10.0”,
“@ionic/storage”: “2.1.3”,
“@types/text-encoding”: “0.0.35”,
“call-number”: “1.0.1”,
“com-sarriaroman-photoviewer”: “^1.2.1”,
“cordova-android”: “6.3.0”,
“cordova-plugin-camera”: “^4.0.3”,
“cordova-plugin-device”: “^2.0.2”,
“cordova-plugin-document-viewer”: “^0.9.10”,
“cordova-plugin-file”: “^6.0.1”,
“cordova-plugin-file-transfer”: “^1.7.1”,
“cordova-plugin-inappbrowser”: “^3.0.0”,
“cordova-plugin-ionic-keyboard”: “^2.1.3”,
“cordova-plugin-ionic-webview”: “^2.4.0”,
“cordova-plugin-kakao-sdk”: “^3.0.0”,
“cordova-plugin-splashscreen”: “^5.0.2”,
“cordova-plugin-whitelist”: “^1.3.3”,
“cordova-sqlite-storage”: “^2.3.2”,
“html-escape-unescape”: “^1.0.3”,
“ionic-angular”: “3.9.2”,
“ionicons”: “3.0.0”,
“kakao-sdk”: “^3.0.0”,
“mx.ferreyra.callnumber”: “~0.0.2”,
“naver-login”: “^1.0.1”,
“naver-sdk”: “^1.0.1”,
“ng2-pdf-viewer”: “^5.1.1”,
“onesignal-cordova-plugin”: “^2.4.1”,
“rxjs”: “5.5.11”,
“sw-toolbox”: “3.6.0”,
“text-encoding”: “^0.7.0”,
“zone.js”: “0.8.26”
},
“devDependencies”: {
“@ionic/app-scripts”: “3.1.11”,
“typescript”: “~2.6.2”
},
“description”: “An Ionic project”,
“cordova”: {
“plugins”: {
“cordova-plugin-whitelist”: {},
“cordova-plugin-device”: {},
“cordova-plugin-splashscreen”: {},
“cordova-plugin-ionic-webview”: {
“ANDROID_SUPPORT_ANNOTATIONS_VERSION”: “27.+”
},
“cordova-plugin-ionic-keyboard”: {},
“cordova-sqlite-storage”: {},
“com-sarriaroman-photoviewer”: {},
“cordova-plugin-camera”: {},
“onesignal-cordova-plugin”: {},
“cordova-plugin-file”: {},
“cordova-plugin-file-transfer”: {},
“cordova-plugin-document-viewer”: {},
“cordova-plugin-inappbrowser”: {},
“cordova-plugin-kakao-sdk”: {
“KAKAO_APP_KEY”: “xxx”
},
“call-number”: {},
“mx.ferreyra.callnumber”: {}
},
“platforms”: [
“android”
]
}
}
Posts: 1
Participants: 1