Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Generate TypeScript typings from Stone specification for NPM distribution #96
Future publications of the dropbox NPM module will now include TypeScript typings
This PR contains the following changes:
The typings should work for people using Dropbox in a variety of settings:
Let me know if you require additional modifications, such as the addition of some type of unit tests.
Unit testing would best be accomplished by compiling sample code against the generated typings. I have two ideas for this:
Hey @jvilk. First off, thanks a lot for the thorough work! A few requests when you can find the time.
Could you rebase this commit on top of master. I would like to merge this Pull request instead of doing it myself. I tested that things work (using your other example repo).
After rebasing, you might want to generate the bindings again to accommodate some routes we added (I can do that myself too; I kept you waiting for a while, so you might have lost context. You did add in the right changes needed to our generator scripts).
I would like to move the example repo into this one. I made a change to make the js examples live in a subfolder(examples/js), but started seeing issues when trying to run the ts examples when they live in a subfolder (instead of a separate repo). So I decided to come back to it later.
This branch is my attempt to do all of the above, it works in the trivial sense, ie, merges and builds correctly. I'll fix the examples-not-working problem, this PR doesn't have to wait for that.
@pran1990 all done! To avoid cluttering up your
I had to remove the rewrite rule in the express server, since it rewrote URLs like
If the examples ever need to be changed, make sure you run
Let me know if you have any trouble with the examples. I encourage you to independently test them in case I missed something important.