1.0.4 • Published 5 years ago

github-as-image-server v1.0.4

Weekly downloads
1
License
MIT
Repository
github
Last release
5 years ago

githubAsImageServer

Build Status npm.io npm.io

A Koa middleware that use github.io as image repository

usage

 npm i github-as-image-server -S
const Koa = require('koa')
const app = new Koa()

const githubAsImageServer = require('../lib');

app.use(githubAsImageServer({
  targetDir: `D:/project/silentport.github.io`, // local path of git repo
  repo: 'https://github.com/silentport/silentport.github.io.git', // address of git repo
  url: 'https://silentport.github.io', // host of your github.io
  dir: 'upload', // dirname will save image
  project: 'blog', // child dirname will save image
  router: '/upload' // path of request
}))


app.listen(8002, () => {
  console.log('server is started!');
})
1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago