Skip to content

y-server-static is a y-server plugin to read/proxy static resource.

License

Notifications You must be signed in to change notification settings

yued-fe/y-server-plugin-static

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

y-server-plugin-static

y-server-plugin-static is a y-server plugin to read/proxy static resource.

Install

npm install y-server-plugin-static

Usage

const path = require('path');

const yServer = require('y-server');
const staticPlugin = require('y-server-plugin-static');

yServer({
  plugins: [
    staticPlugin({
      staticPaths: {
        '/test': path.join(__dirname, 'test'),
        '/lbf': 'https://qidian.gtimg.com/lbf/1.0.4',
      },
    }),
  ],
});

Notes

  • staticPaths is the Object which will be read/proxy.

License

MIT License

About

y-server-static is a y-server plugin to read/proxy static resource.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published