-
-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationrefactorRefactor a past featureRefactor a past featuretestAdding missing tests or correcting existing testsAdding missing tests or correcting existing tests
Description
Description
addConfig, removeConfig and resetConfig could be a little confusing and not so performative because it creates new instances of the Driver every time one of this methods are called.
A better way to handle it is just using the Storage constructor:
const runtimeConfigs = {
bucket: 'test',
}
const storage = new Storage(runtimeConfigs)Or disk method:
const runtimeConfigs = {
bucket: 'test',
}
const storage = new Storage()
storage.disk('s3', runtimeConfigs)Both implementation are useful, because you can remove/reset the runtimeConfig in Storage using disk method, this way you don't need to create a new instance of Storage.
Package version
1.0.2
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationrefactorRefactor a past featureRefactor a past featuretestAdding missing tests or correcting existing testsAdding missing tests or correcting existing tests