1.0.0 • Published 1 year ago

express-browser-detect v1.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

It uses which-browser under the hood, and all the documentation is there

Installation

yarn add --save express-browser

Or if you prefer npm

npm install --save express-browser

Example

const express = require('express');
const app = express();
const port = 3000;
const ex_browser = require('express-browser');

app.use(ex_browser);

app.get('/', (req, res) => {
  res.send('Your browser is: ' + req.browser.browser.toString());
})

app.listen(port, () => {
  console.log(`Example app listening on port ${port}`);
})
1.0.0

1 year ago