dropbox.js is written in CoffeeScript, which compiles into very readable JavaScript. This document addresses the concerns that are commonly raised by JavaScript developers that do not use or wish to learn CoffeeScript.
No.
The examples in the getting started guide are all written in JavaScript. The dropbox.js API reference covers the entire library, so you should not need to read the library source code to understand how to use it.
Please open an issue if the documentation is unclear!
The sample apps, are written in CoffeeScript. Please use the
Try CoffeeScript
button on the CoffeeScript home
page to quickly compile the sample CoffeeScript into very readable JavaScript.
The easiest method is to use the <script>
tag in the
getting started guide, which loads dropbox.js from a
CDN.
If you wish to server dropbox.js from your own server, the easiest solution is to download the cdnjs copy of dropbox.js.
If you want to keep up with new dropbox.js releases, a reasonably convenient
method is to install the dropbox
package via npm, and
serve node_modules/dropbox/lib/dropbox.js.min
. Updating the npm package will
keep you up to date.
No.
You can follow the development guide to build the
un-minified JavaScript library in lib/dropbox.js
and then use your editor's
find feature to get to the source code for the methods that you are interested
in.
The building instructions in the development guide do not require familiarity with CoffeeScript.
Yes, but you might not need to modify the library.
You do need to learn CoffeeScript to change the dropbox.js
source code. At
the same time, you can take advantage of the library hooks and the dynamic
nature of the JavaScript language to change the behavior of dropbox.js
without touching the source code.
- You can implement your OAuth strategy.
- You can add methods to the prototype classes such as
Dropbox.Client
to implement custom operations. Please open an issue if you think your addition is generally useful! - You can replace internal classes such as
Dropbox.Util.Xhr
(or selectively replace methods) with wrappers that tweak the original behavior
Yes.
Most of the development time is spent on API design, developing tests, documentation and sample code. Contributing a good testing strategy with a bug report can save us 90% of the development time. A feature request that also includes a well thought-out API change proposal and testing strategy can also save us 90-95% of the implementation time.
At the same time, please open issues for bugs and feature requests even if you don't have time to include any of the above. Knowing of a problem is the first step towards fixing it.
Last, please share your constructive suggestions on how to make dropbox.js
easier to use for JavaScript developers that don't speak CoffeeScript.
No.