1.0.3 • Published 4 years ago
@osjs/gdrive-adapter v1.0.3
OS.js is an open-source web desktop platform with a window manager, application APIs, GUI toolkit, filesystem abstractions and much more.
OS.js Google Drive VFS Adapter
This is the Google Drive VFS (Client) Adapter for OS.js.
This is not done and might damage your files!
Installation
npm install @osjs/gdrive-adapter @osjs/gapi-provider
Usage
Requires @osjs/gapi-provider
set up with the following configuration (see separate docs):
client: {
discoveryDocs: ['https://www.googleapis.com/discovery/v1/apis/drive/v3/rest'],
scope: ['https://www.googleapis.com/auth/drive']
}
In your client initialization script:
import gdriveAdapter from '@osjs/gdrive-adapter';
osjs.register(VFSServiceProvider, {
depends: ['osjs/gapi'],
args: {
adapters: {
gdrive: gdriveAdapter
}
}
});
Then create a mountpoint:
{
vfs: {
mountpoints: [{
name: 'gdrive',
label: 'Google Drive',
adapter: 'gdrive'
}]
}
}
Contribution
- Sponsor on Github
- Become a Patreon
- Support on Open Collective
- Contribution Guide
Documentation
See the Official Manuals for articles, tutorials and guides.
Links
1.0.3
4 years ago