dropbox-sdk-js icon indicating copy to clipboard operation
dropbox-sdk-js copied to clipboard

Generate typings for version 4.0.15

Open Bohdan-Tereta opened this issue 7 years ago • 6 comments

declare module DropboxTypes { interface DropboxOptions { // An access token for making authenticated requests. accessToken?: string; // The client id for your app. Used to create authentication URL. clientId?: string; // Select user is only used by team endpoints. It specifies which user the team access token should be acting as. selectUser?: string; // Root path used to access namespaces different from home namespace (team folders etc) pathRoot?: string; // Fetch library for making requests. fetch?: Function }

'pathRoot' and 'fetch' parameters are in dropbox_types.d.tstemplate but not in dropbox_types.d.ts, need to generate types from templates otherwise newly added parameters aren't usable in typescript

Bohdan-Tereta avatar Jan 08 '19 12:01 Bohdan-Tereta

Thanks for the report! I'll ask the team to fix that up.

greg-db avatar Jan 08 '19 17:01 greg-db

It is also needs adding to the DropboxTeam class actAsUser function, so that it gets passed to the new instance of the Dropbox class used there.

michellemv avatar Jan 22 '19 11:01 michellemv

@michellemv Thanks for the note! I'll ask the team to work on that as well.

greg-db avatar Jan 22 '19 18:01 greg-db

Problem solved in this commit: https://github.com/dropbox/dropbox-sdk-js/commit/bb3dca3d2d07044b12f69f3fdfdf981be5d00d8f

need to close this issue. @greg-db @Bohdan-Tereta what you think?

alexandrtovmach avatar Mar 07 '19 07:03 alexandrtovmach

Thanks for pointing that out!

greg-db avatar Mar 07 '19 16:03 greg-db

Works for me, fetch and pathRoot params are recognized in typescript now

Bohdan-Tereta avatar Mar 07 '19 17:03 Bohdan-Tereta