Your workflow is unique 👨💻 - tell us how you use Dropbox here.
Forum Discussion
Valarpirai
10 years agoNew member | Level 1
JS SDK: Error: dropbox.js loaded in an unsupported JavaScript environment.
Hi,
I am developing a firefox extension. Here, I have tried to use dropbox datastore as storage. I am not able to load JS SDK in firefox extension. Reference extension is https://github.com/cgav/dropbox-firefox-extension
I am getting the following error in console.
console.error: firefox-extension:
Message: Error: dropbox.js loaded in an unsupported JavaScript environment.
Stack:
Resource://jid1-rpqb40q3z1iksq-at-jetpack/nekt/lib/tplib/dropbox-datastores-1.2-latest.js:2:1114
@resource://jid1-rpqb40q3z1iksq-at-jetpack/nekt/lib/tplib/dropbox-datastores-1.2-latest.js:2:1
CuddlefishLoader/options<.load@resource://gre/modules/commonjs/sdk/loader/cuddlefish.js:129:18
initDropbox@resource://jid1-rpqb40q3z1iksq-at-jetpack/nekt/lib/background.js:81:17
Background@resource://jid1-rpqb40q3z1iksq-at-jetpack/nekt/lib/background.js:112:2
@resource://jid1-rpqb40q3z1iksq-at-jetpack/nekt/lib/background.js:121:18
CuddlefishLoader/options<.load@resource://gre/modules/commonjs/sdk/loader/cuddlefish.js:129:18
run@resource://gre/modules/commonjs/sdk/addon/runner.js:145:19
startup/</<@resource://gre/modules/commonjs/sdk/addon/runner.js:86:7
Handler.prototype.process@resource://gre/modules/Promise-backend.js:870:23
this.PromiseWalker.walkerLoop@resource://gre/modules/Promise-backend.js:749:7
this.PromiseWalker.scheduleWalkerLoop/<@resource://gre/modules/Promise-backend.js:691:37
3 Replies
Replies have been turned off for this discussion
- Rich10 years ago
Super User II
Moved to the API forum.
- Greg-DB10 years ago
Dropbox Community Moderator
The Dropbox JavaScript library checks a few things (e.g.,
windowandnavigator) to make sure it's in an environment where it can work correctly. If it doesn't find those things it throws that error to let you know. Unfortunately I don't think there's a good solution here, as the library wasn't built to support running in a Firefox extension.By the way, note that the Datastore API has been deprecated:
https://blogs.dropbox.com/developers/2015/04/deprecating-the-sync-and-datastore-apis/
- Valarpirai10 years agoNew member | Level 1
Greg,
Thanks for your valuable response.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!