Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Companion Inbox Documentation - error

ANSWERED

I don't know how this passed any kind of documentation QA, the following code in the companion inbox documentation is just plain wrong:

import { inbox } from "file-transfer";
inbox.onnewfile = (event) => {
   console.log(`Received $‌{event.file.length} bytes as $‌{event.file.name}`);
}

The event object has no property named file.

See the file transfer guide documentation for the correct handling:

https://dev.fitbit.com/build/guides/communications/file-transfer/#companion-inbox

 

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

Thanks for letting us know. I'll get this updated with a working example.

View best answer in original post

Best Answer
0 Votes
1 REPLY 1

Thanks for letting us know. I'll get this updated with a working example.

Best Answer
0 Votes