Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add @uppy/remote-sources preset/plugin #3676
Add @uppy/remote-sources preset/plugin #3676
Changes from 13 commits
ac1f5df
04dd8c7
3fd0002
3af5fe9
c6cd1bb
54e51e7
d3eb0c0
f65e456
d2fe057
c1bfc95
d249bea
fba2ffe
76a760c
9bf0d67
f4ba2aa
8106fda
18b1172
d686ebb
454ad85
a455bf8
15e715d
e57111e
b498178
fa53fbc
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That looks unrelated, can we put it in its own PR (or remove it)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't be worried that
this.opts.sources
can be modified by the user and theuninstall
would not work correctly? Another (better?) way of handling it would be to have a privateSet
on the instance that caches all the plugins that were installed.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it sounds better, not sure if Set is required or just a private array. But I did think of this, if you modify options the correct way via
uppy.getPlugin('RemoteSources').setOptions({ sources: ['Instagram'] })
, the plugin will first uninstall everything, then update options and install back: https://github.com/transloadit/uppy/pull/3676/files#diff-3b90938b025125a702e11b69f66acdd0c6985a892f64f4a28b06f0dcdb24e873R51-R55There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should not assume that users will always use the correct way.
I think
Set
is more suited for our use case, but I suppose an array would also work.