You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But with typescript it says that is missing one argument, in that case is callback, Then, I put the callback, but get another error that says (translate from Spanish):
Cannot assign an arg of type "{ topic: string; payload: string; qos: 0; }" to param of type "PublishPacket".
to type "{ topic: string; payload: string; qos: 0; }" is missing the following properties of type "IPublishPacket": cmd, dup, retain
It suppose that these properties should be defaults or optional, also the docs doesn't offer explanation of what properties have or what is PublishPacket. I know that properties are standard of mqtt, but at least a external link or something.
Also, I got another error with aedes.authenticate 'authenticate' does not exist on type 'aedes'
The code can run, at least I don't use typescript. Adding // @ts-expect-error ignore the problem. But, how I can import the type definitions?
The text was updated successfully, but these errors were encountered:
@DrakoPOD you can add the authenticate function in aedes options
It suppose that these properties should be defaults or optional, also the docs doesn't offer explanation of what properties have or what is PublishPacket
Yeah them are not mandatory, I think types could be improved here. Would you like to submit a PR to fix them?
I have this code, that works perfectly in vanilla JS:
But with typescript it says that is missing one argument, in that case is
callback
, Then, I put the callback, but get another error that says (translate from Spanish):It suppose that these properties should be defaults or optional, also the docs doesn't offer explanation of what properties have or what is
PublishPacket
. I know that properties are standard of mqtt, but at least a external link or something.Also, I got another error with
aedes.authenticate
'authenticate' does not exist on type 'aedes'
The code can run, at least I don't use typescript. Adding
// @ts-expect-error
ignore the problem. But, how I can import the type definitions?The text was updated successfully, but these errors were encountered: