Phonegap Push plugin won't work


#1

I have a problem with FCM notification. Ihave installed the phonegap plugin and followed this guide:

but visual-studio-code report to me the following error:

Can you help me?


#2

Does it build and work anyway?

What is your ionic info output?


#3

No, doesn’t build and work.
the Output error is the follow

[14:56:29] typescript: src/app/app.component.ts, line: 60
Type ‘{ android: { senderID: string; sound: true; vibrate: true; }; }’ is not assignable to type
’PushOptions’. Types of property ‘android’ are incompatible. Type ‘{ senderID: string; sound: true; vibrate:
true; }’ is not assignable to type ‘AndroidPushOptions’. Object literal may only specify known properties,
and ‘senderID’ does not exist in type ‘AndroidPushOptions’.

  L59:  android: {
  L60:    senderID: 'YOUR_SENDER_ID',
  L61:    sound:true,

Error: Failed to transpile program
at new BuildError (/home/giovanni/Scrivania/git-giovanni/pizzashop/node_modules/@ionic/app-scripts/dist/util/errors.js:16:28)
at /home/giovanni/Scrivania/git-giovanni/pizzashop/node_modules/@ionic/app-scripts/dist/transpile.js:137:20
at Promise ()
at transpileWorker (/home/giovanni/Scrivania/git-giovanni/pizzashop/node_modules/@ionic/app-scripts/dist/transpile.js:103:12)
at Object.transpile (/home/giovanni/Scrivania/git-giovanni/pizzashop/node_modules/@ionic/app-scripts/dist/transpile.js:61:12)
at buildProject (/home/giovanni/Scrivania/git-giovanni/pizzashop/node_modules/@ionic/app-scripts/dist/build.js:97:78)
at /home/giovanni/Scrivania/git-giovanni/pizzashop/node_modules/@ionic/app-scripts/dist/build.js:47:16
at


#4

Ugrade your phonegap plugin to 2.0.1 and put google-services.json in android folder and project root folder and most important please remove senderid from android and refer to ionic-native push plugin page for rereference.