Ionic3 native local-notification problem

< H2 > ionic enters the pit using native message push function < / H2 >
TypeError: Object(...) is not a function
    at LocalNotifications.schedule (index.js:49)
    at new SchedulePage (schedule.ts:39)
    at createClass (core.js:12491)
    at createDirectiveInstance (core.js:12326)
    at createViewNodes (core.js:13784)
    at createRootView (core.js:13673)
    at callWithDebugContext (core.js:15098)
    at Object.debugCreateRootView [as createRootView] (core.js:14381)
    at ComponentFactory_.create (core.js:11278)
    at ComponentFactoryBoundToModule.create (core.js:4030)

https://ionicframework.com/do...
always mistakenly reported that he could not find it at first. Then he added"/ ngx"
import {LocalNotifications} from"@ ionic-native/local-notifications/ngx";
to the official website after import. I thought it would work. When I use the result below, I report an error directly
, but I can find this function

when I print it in the console.

clipboard.png



clipboard.png
friends who are in trouble help me


if you read the error message, it should not be a question of whether the function schedule is present or not. This function has been called successfully. The error is caused by calling the relevant methods of Object in this function

.

as for the possible cause of the error, your @ ionic-native/core version is incompatible.

here are two links that may help you solve the problem.

Ionic 4: Object () Is not a function

Ionic Local Notifications (Schedule, Payload and Callback) v3

Menu