node-file-manager-esm
Version:
A simple file manager, based on Koa and Angular.js. Standalone, Koa-mountable. Import-able as ES6 and Babel module.
18 lines (10 loc) • 328 B
JavaScript
import Koa from 'koa';
import mount from 'koa-mount';
import appFilemanangerLoader from '../index';
const appMain = new Koa();
var appFilemananger = appFilemanangerLoader(null, 'zip|txt|mp4').app;
appMain.use(mount('/fm', appFilemananger));
appMain.use((ctx, next) => {
ctx.body = 'go to /fm';
});
appMain.listen(3000);