0.0.8 • Published 6 years ago

this-computer v0.0.8

Weekly downloads
3
License
MIT
Repository
github
Last release
6 years ago

this-computer

Including volumes, directory listing library

ATTENTION, this is alpha release. Not tested yet

import {volumes, listFolder} from 'this-computer'

// returns JavaScript Promise
let volumes = await volumes()

// output
{
 baseFolder : "This Computer",
 subFiles : [
                { name : "C:", path : "C:" },
                { name : "D:", path : "D:" }
            ]
}

// returns JavaScript Promise as well
let path = "C:\\myFolder\\mySubFolder"
listFolder(path).then( (data) => {

    console.log(data)
    // Output
    {
    baseFolder : "C:\\myFolder\\mySubFolder",
    subFiles : [
                    { name : "..", path : "C:\\myFolder\\" },
                    { name : "file1.js", path : "C:\\myFolder\\mySubFolder\file1.js" },
                    { name : "file2.js", path : "C:\\myFolder\\mySubFolder\file2.js" }
                ]
    }
})
0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago