1.0.0 • Published 7 years ago
express-whs v1.0.0
Express-WHS 1.0.0
Installation
Expressjs Middleware (Server-Side)
npm install --save express-whs
Client Side Module
bower install whstorage
npm install whstorage
yarn add whstorage
Usage
const express = require('express')
const whs = require('express-whs')
/*
* Define Exprees App
*/
const app = express();
app.use(whs({
prefix: 'wh',
secret: 'thisismysecret',
keySize: 36
}))
/*
* send to client
*/
app.get('/api', (req, res, next) => {
res.send({
whKey: req.wh_Key,
prefix: req.wh_prefix
})
})
1.0.0
7 years ago