这是一个基于Vue的轻量级文件管理器,包含了大部分web文件操作.
npm install --save oss-explorer
<template>
<div id="app">
<explorer
v-model="objects"
:token="token"
:meta="meta"
:stsPath="stsPath"
:multiple="true"
:path="path"
:privatePath="privatePath"
:limit="5"
:maxKeys="1000"
@select="onSelect">
</explorer>
</div>
</template>
<script>
import Explorer from 'oss-explorer'
import 'oss-explorer/dist/oss-explorer.css'
export default {
name: 'app',
components: {
Explorer
},
data () {
return {
clientConfig: null,
token: localStorage.token,
path: '',
privatePath: '',
stsPath: ``,
objects: [],
meta: {}
}
}
}
</script>
<style>
</style>
更多用法请参考demo
npm install
npm run serve
npm run build
npm run test
npm run lint
npm run test:unit